Re:FBG – Lightweight C Linux framebuffer graphics with paral...
by Vendan on Monday June 18, 2018 @10:38AM
(#17338562)
Linux frame buffer is perfectly capable of doing 2 pages and "flipping" without memcpy. Just have it initialize a double height virtual screen, and then use a panDisplay IOCTL to swap between them.
Re:FBG – Lightweight C Linux framebuffer graphics with paral...
by onirom on Tuesday June 19, 2018 @01:50PM
(#17348800)
Tried to implement page flipping today and performances are terribly low on the Raspberry PI due to direct draw calls to the video mapped memory... so you need to do a single memcpy to avoid multiple write to the video mapped memory, this result in the initial behavior.
Re:FBG – Lightweight C Linux framebuffer graphics with paral...
by Vendan on Wednesday June 20, 2018 @11:26AM
(#17356266)
Generate single frame, copy to "off page", flip. This prevents tearing.
Re:FBG – Lightweight C Linux framebuffer graphics with paral...
by onirom on Thursday June 21, 2018 @03:05PM
(#17368309)
Yes, this is actually how it work however page flipping mechanism require a memcpy, as such it is as effective as not using page flipping and just memcpy a front buffer to display and doing software flipping through pointers exchange, the only advantage of using page flipping is that it require much less operations and prevent tearing but performance wise, it is roughly the same.
Re:FBG – Lightweight C Linux framebuffer graphics with paral...
by raverbashing on Monday June 18, 2018 @11:40AM
(#17339055)
I see your point. You still need to copy the data to the buffer.
But yeah, don't expect smooth animations without a dual buffer.
No, it is as fast as it gets and it's the correct way of doing it (in fb at least).