DirectX - page 9

 
Реter Konow:

OK, made the glass in the editor. Took me two hours. That's a lot of fuss. You can speed up the process by a factor of four by adding tools.

Tested it.

The result: less than 20% of load with constant change in all cells ask and bid, and one cell price, at 40 frames per second. (The load rises by 5-7 percent when recording is enabled).


I repeat my opinion - in real conditions the load will be 5 - 10 percent depending on market activity.

What kind of processor do you have?

Do you write the screen using MQL tools?

How is the data coming into the glass for simulation purposes - from a file?

 
Aleksey Vyazmikin:

What kind of processor do you have?

Do you write the screen using MQL tools?

How is the data coming in for simulation purposes - from a file?

Processor is old - i3.

The slider is created in a self-made visual editor written in MQL. It's publicly available but needs improvement. It's not finished, but simple windows can be created relatively quickly and easily.

The data comes from the EA. They are random numbers sent to the cells of the glass from the timer function.

 
Реter Konow:

The processor is an old i3.

The stack is created in a homemade visual editor, which is written in MQL. It's publicly available, but needs tweaking. It's not finished, but simple windows can be created relatively quickly and easily.

The data comes from the EA. It's random numbers sent to the stack cells from the timer function.

So there are 4 threads, and 1 thread is 25%, i.e. the load on the screen is maximum, and there are probably frame drops.

Where can this editor be viewed?

If from a timer, then you can't estimate different load. And what is the rate of value generation per second?

 
Took an empty loop with Sleep and an empty shader. On a 900x900 window, CPU load is less than 20% at 20 fps.
 
Aleksey Vyazmikin:

1. So 4 threads, and 1 thread is 25%, i.e. the load in the screenshot is maximum, and there are probably frame drops.

2. Where can this editor be viewed?

3. If from timer, then you can't estimate different load. And what is the value generation rate per second?

1. I already made a working beaker and checked - the load was from 1 - 5%. Can't find that code now...

2.https://www. mql5.com/ru/blogs/post/733700 (There will be a powerful update tomorrow, if I have time.

3. 40fps (25ms).

ВИЗУАЛЬНЫЙ РЕДАКТОР
ВИЗУАЛЬНЫЙ РЕДАКТОР
  • www.mql5.com
Распакуйте архив и установить советник KIB.ex5 в папку экспертов, а индикатор KIB-source.ex5 в папку индикаторов. Запустите сначала советник, потом индикатор. 1. Появится окно меню. Оно содержит базовые элементы управления. 2. После загрузки индикатора, появится путое окно для редактирования. 3. Перетаскивайте элементы из окна меню на канвас...
 
Rorschach:
Took an empty loop with Sleep and an empty shader. On a 900x900 window, CPU load is less than 20% at 20 fps.

Cool! All that's left to master is...

 

DirectX is not really interesting, but I built a table and WinForms in C# in 15 minutes.

From MQL5 I throw an array with double[] data once every 5 ms, I don't see any load on the CPU, maybe I'm looking in the wrong place, but it works fine

Files:
MQL5.zip  205 kb
 
Igor Makanu:

DirectX is not really interesting, but I built a table and WinForms in C# in 15 minutes.

I throw a double[] data array every 5 ms from MQL5. I don't see any load on CPU, maybe I'm looking in the wrong place, but it works fine.

Nothing changes. Please run the check in the way I have shown you with the tumbler.

And how can you throw an array every 5ms when the minimum timer frequency is 15ms ?
 
Реter Konow:
And how can I throw an array every 5 ms if the minimum timer frequency is 15 ms?

it is not important (16 ms is the minimum possible timer from Win), anyway dll call works in the same thread with MQL, until the call is completed MQL will sleep

i wonder another thing, why cpu load is not visible, well sometimes MT has up to 2% load, very little - i ran it on a laptop, it has a weak CPU

 
Igor Makanu:

it is not important (16 ms is the minimum possible timer from Win), anyway dll call works in the same thread with MQL, until the call is completed MQL will sleep

i wonder another thing, why cpu load is not visible, well sometimes it is up to 2% load, very little - i used a laptop, it has a weak CPU

And where are the changes in the table? Is it being redrawn?