Canvas is cool! - page 9

 
Nikolai Semko:

Oh, come on.
I'll make life easier.

I will give you the code as an example.

Of course, a faster algorithm could be implemented. But this is the first thing that came to my mind.

I just don't get it.
Why, if the pause between frames is set to 0, I personally get this distortion on my computer from time to time:


What kind of de-synchronisation is this?
This doesn't happen with the default pause (30 milliseconds), or it happens much less often.
The algorithm, it turns out, has nothing to do with it. Where does this shift come from, then? I don't understand!

If the reason is an asynchronous command, then what is it?

 
How do you put animations like gifs on the graph?
 
Maxim Dmitrievsky:
How do you put animations like gifs on a graph?

That's how I presented the code in this post.

It's not a gif. It's a regular BMP file with a smoothly changing size (scaling)

 
Nikolai Semko:

That's how I presented the code in this post.

It's not a gif. This is a regular BMP file with smoothly changing size (scaling)

So, you can't convert ready animated gif? For example, you can't just change size but create full animation, you don't have to draw it yourself

 
Maxim Dmitrievsky:

So there's no way to convert a ready animated gif? For example, not just a size change but a full-fledged animation, so that you don't have to draw it yourself

Yes, you can. You want to watch movies. You just have to write a codec. All today's video formats have powerful compression algorithms. You have to understand them.
Gifs are also possible, but the same problem - you have to know this format, how to cut out frame by frame, I personally have no idea. For now, in mql5, there is only bmp among graphical formats.

bmp is the most primitive format. It's just an uncompressed array of pixels.
It would be great if there were also png. The png has one big advantage over bmp: it's much smaller in size for the same quality.
Another question is why?

Of course, you don't have to. BMP is, in principle, quite enough for the tasks at hand.

 
Nikolai Semko:

Yes, you can. You can even watch films. You just have to write the codecs. All of today's video formats have powerful compression algorithms. You need to understand them.
Gifs are also possible, but the same problem - you need to know this format, how to pull out frame by frame - I personally have no idea. For now mql5 only has bmp as one of the graphical formats.

bmp is the most primitive format. It's just an uncompressed array of pixels.
It would be great if there were also png. The png has one big advantage over bmp: it is much smaller for the same quality.
Another question - why do you need it?

Of course you don't. BMP is quite enough for the task at hand.

Well, maybe you don't need it, it would be cool to insert animation into panels without any effort

but if it's so complicated, of course not :)

 
Maxim Dmitrievsky:

Well, maybe you don't have to, it would just be fun to insert a gif animation into the panels, for example, without too much effort

but if it's so complicated, don't bother :)

I'm personally in favor of simulated vector graphics.

Here was an example of how you can combine vector and bitmap graphics. The result is a smooth change in font size, which can be useful in more advanced GUIs.

 
Alexey Volchanskiy:

I remember those days very well, but I am not nostalgic. And I remember the ISA bus, it was the last bus, for which I made homemade measuring boards for equipment, which I painted with nail polish and etched with ferrous chloride. I get nostalgic about my youth and girls, but not about the hardware of that time ))

And '81 was for the West, for me it was about '90. In '81 or a bit later I was taught in the good old Bonch-Bruevich to program on a computer Nairi, which was a domestic development of the early 60s, without a monitor, but with a typewriter which was used for the dialog. Not nostalgic either :)

Well, for me it's about the same, and about the same time. To tell the truth, I've started with a programmable calculator, then I studied for some time the K580VM80 processor, even made my own computer-calculator (I took the 88 UT, the K580VK28 motherboard bus controller, 537RF5 ROM, 537RU10 memory - two kilobytes, seven-segment matrix LEDs display). I was assured, that without software the computer was nothing (even for myself).

Then I got in a company with relatively free access to a CM1810, which was a fully PC XT-compatible machine. I've got the same opinion as you: CGA sucks, it's not good for playing games. Much worse than Sinclair Spectrum or Commodore 64.

Actually it's a very good and correct adapter. It had a composite output for gaming and multicolouring. In addition, in compositing mode you had a choice between multicolour, but with "blurry", shimmering text, or with four predefined colours in high quality text.

If you take the RGB output, you get even better quality text. Just in that office there was not a composite, but a digital RGB monitor. Graphics - you lose the multicolour, but there is still quite a wide choice. There's 640x200 at any two colours and 320x200 at four predefined colours (from two palettes). In all cases, the picture sharpness - was higher than on the "Spectrum". But, multicolour was sacrificed. Which, for business, was quite reasonable.


And my nostalgia is the same as yours... For women - yes, I am nostalgic (I had far fewer of them than you)... For my youth... Health... That's nostalgia. And the tin can't help it... Tin cans.

 
Georgiy Merts:


For lovers of nostalgia...
ZX-Spectrum emulators:

https://www.emu-land.net/computers/zx_spectrum/emuls/windows

Home
  • emulationrealm.net
The Emulation Realm is a rather large archive of emulators, plugins, frontends, rom managers, and more. Daily updates with reviews and easy navigation.
 
Nikolai Semko:

Oh, come on.
I'll make life easier.

I'll give you the code as an example.

Thank you, Nikolai. I won't forget your sacrifice! :)

Reason: