Do you have a solution for the flickering problem encountered when writing ZIGZAG type indicators on MT5? Is it a logic problem for MT5 to render the indicator buffer? - page 10

 
Miguel Angel Vico Alba #:

伙计们,伙计们,伙计们.....闪烁是由于重新计算。将图表中的最大柱数限制为例如 1000。


It has been set, I just give feedback, it still exists.

 
Kaijun Wang #:

69# also have this problem,

#69 also on a low resource machine

 

1

不去关注问题本身,难道因为你的杠ZIGZAG就不闪烁了?

 
In the GIF it is showing that it is still using the unlimited bars, so the indicator has to build the lines with hundreds of thousands of calculations (front to back).

As already mentioned your computational "power" doesn't help either (low memory, cpu and I assume a mechanical HDD (not SSD).
 
Miguel Angel Vico Alba #:
In the GIF it is showing that it is still using the unlimited bars, so the indicator has to build the lines with hundreds of thousands of calculations (front to back).

As already mentioned your computational "power" doesn't help either (low memory, cpu and I assume a mechanical HDD (not SSD).

The laptop I use is actually not as bad as you think. My boot speed is still 3 to 5 seconds...you don't have an intuitive experience of other fluency...otherwise I wouldn't have opened the full taskbar program Still doing everything smoothly. It’s just that the ultrabook does not include a graphics card. Although the CPU is also poor, it is not garbage.

In addition, I also used DRAWLINE to build an algorithm to draw ZIGZAG, which does not flicker. Only the related types of ZIGZAG BUFERR and SECTION provided by the system will have this problem.

Thank you very much, I will eat first.

 
Kaijun Wang #:

Try limiting the number of bars in the code.

int bars = iBars(_Symbol, PERIOD_CURRENT);

for (int i=0; i<bars && i<500; i++)
 
Fernando Carreiro #:

I have my charts at maximum number of bars and calculate the buffers for every single bar.

I have never had any flickering on MT4 or MT5 ever.

It seems that maybe something in your code is the cause. Maybe it is recalculating buffers on each call instead of only updating the changes.

Without seeing your code, it will be difficult to offer any advice.



Hi, I downloaded someones Sessions indicator and the colored squares he made for each countries FOREX session Flicker in MetaTrader 5 but they do NOT Flicker in MetaTrader 4. Is this the same problem being mentioned on this page with the Zig/Zag issue?  Trading Session Time with Alerts by Issam Kassas Flickers in MetaTrader 5 but it doesn't Flicker in MetaTrader 4.  There are colored squares for each countries Trading session and the squares Flicker randomly. It's very distracting. I tried to email this guy but he doesn't respond to me. The only option I have it just to turn off the colors and then its fine. I really like his indicator but the random flickering of the squared colors is very distracting while daytrading.
 
Kaijun Wang:

A few years ago, I found a very strange phenomenon in the process of writing MT5 indicators ->>

Let me first talk about my code entry process:

1. The refresh of controls written by MT5 will flicker. When I started writing the trading assistant panel, I found that when I used the CANVAS sketchpad to refresh the display content of the controls, MT4 responded very quickly and did not feel refreshed, but MT5 There will be a flickering process, and it is obvious to see the white screen time of the control with an interval of 0. a few seconds

2. I made a ZIGZAG indicator with a very complex algorithm. Like 1, I will make two different MT4 and MT5 versions with the same function and display, which means that for users, they use the same function But this problem happened to trouble me for several years, because the buyers of the MT5 version of this indicator basically did not give me feedback on this problem, even if I found this problem myself, but because of my debugging results, it may be caused by MT5. When the data is loaded into the indicator buffer of ZIGZAG, it will keep blinking

3. When it comes to the flickering problem of the 2-point indicator, the flickering at that time was just a flickering feeling, and there would not be a long white screen time, but now I find that with the update of MT5, the white screen gap is getting longer and longer -> (Note: I use DRAW_SECTION type BUFFER for 1 and 2), I have been in MT4 and MT5 programming for more than ten years, but I have not seen the progress of MT5 in these years, but I am a BUG maker. The flickering problem alone , the same code logic, the code operation can perfectly render the effect in MT4, but MT5 just can’t, although I feel that this may be a problem with the graphics rendering logic of MT5, does it also mean that MT5 is doing too poorly in this aspect?

The indicator flickers seriously. The gif picture is as follows. Not only does it flicker, but it will also be white for a long time without rendering.


Friends who

Hi, I downloaded someones Sessions indicator and the colored squares he made for each countries FOREX session Flicker in MetaTrader 5 but they do NOT Flicker in MetaTrader 4. Is this the same problem being mentioned on this page with the Zig/Zag issue?  Trading Session Time with Alerts by Issam Kassas Flickers in MetaTrader 5 but it doesn't Flicker in MetaTrader 4.  There are colored squares for each countries Trading session and the squares Flicker randomly. It's very distracting. I tried to email this guy but he doesn't respond to me. The only option I have it just to turn off the colors and then its fine. I really like his indicator but the random flickering of the squared colors is very distracting while daytrading.

experience in writing code indicators


Regarding the problem of refreshing the white screen of the control data I encountered at point 1, I solved it in this way later: I added a logical judgment before refreshing the display of the control, first judging that the data has changed, and then refreshing the content on the Bitmap_label.... Although this cannot be eradicated, it can basically reject invalid flickering. Other similar writings are solved in this way.

OBJ_BITMAP_LABEL


I hope that the post will be popular, so that MQL5 official programmers can also see it. After all, MT5 has been used and found that although many improvements have been made to indicators such as color filling, such as color-changing line support, it is better than MT4. But in terms of graphics rendering ( I can only attribute it to the fact that you have different rendering logics for indicator buffers) In the K-line data refresh logic of MT5, it is a BUG manufacturing machine, because I have seen this flickering problem for two or three years in my waiting It is getting more and more serious, under the premise that the code remains unchanged.

You are also welcome to guide me, how to write the ZIGZAG indicator of MT5 and the experience of MT4 are the same.

Hi, I downloaded someones Sessions indicator and the colored squares he made for each countries FOREX session Flicker in MetaTrader 5 but they do NOT Flicker in MetaTrader 4. Is this the same problem being mentioned on this page with the Zig/Zag issue?  Trading Session Time with Alerts by Issam Kassas Flickers in MetaTrader 5 but it doesn't Flicker in MetaTrader 4.  There are colored squares for each countries Trading session and the squares Flicker randomly. It's very distracting. I tried to email this guy but he doesn't respond to me. The only option I have it just to turn off the colors and then its fine. I really like his indicator but the random flickering of the squared colors is very distracting while daytrading.