Skip to main content
GameDev.net gamedev.net
🔒 Locked

Linux frame buffer question

Started by Silent Dragon Aug 28, 2008 at 12:36 PM 3 replies 1.4k views
Original Post
Silent Dragon
Silent Dragon
Hi guys, Not really sure where this fits, as it's not related to Game Programming at all, it's just a general question..so anyway. Is it possible to have more than 1 frame buffer on linux? And/Or is it possible to hide the frame buffer from view? Basically I want to be able to render on it and then write it out to a file, at the moment it does that, but the frame buffer is visible which isn't really what I want, plus when 2 instances of the program is running they write over each other on the frame buffer. Anyway, any insite would be greatly appreciated. Thanks, - SD
Koobazaur
Koobazaur
I haven't done any linux coding so I may be completely off, but isn't a frame buffer effectively just a chunk of memory? Can't you create a chunk of memory of the same size (malloc), write to it, and then copy it to your frame when necessary (memcpy) ?
Comrade, Listen! The Glorious Commonwealth's first Airship has been compromised! Who is the saboteur? Who can be saved? Uncover what the passengers are hiding and write the grisly conclusion of its final hours in an open-ended, player-driven adventure. Dziekujemy! -- Karaski: What Goes Up...
Prefect
Prefect
I'm not really sure what you're referring to - are you talking about the in-kernel framebuffer drivers? If so, they are a feature that is so rarely used by normal people that you're probably not going to find help here. You should just work with libraries based on X unless you want to do development for embedded devices. And if you want to do development for embedded devices using Linux, you are even less likely to find somebody here who is able to help you.

Besides, wouldn't the Everything Unix forum be more appropriate for this thread?
Widelands - laid back, free software strategy
Raghar
Raghar
Quote:
Original post by Silent Dragon
Basically I want to be able to render on it and then write it out to a file, at the moment it does that, but the frame buffer is visible which isn't really what I want, plus when 2 instances of the program is running they write over each other on the frame buffer.


Isn't a framebuffer allways visible by definition? Render to texture.

Silent Dragon
Silent Dragon
Eh, thanks for the replies. It was a long shot really, I didn't expect anyone to give the perfect answer. Yeah the frame buffer is just a piece of memory, and i was referring to the in-kernel framebuffer. What I didn't realise when I wrote the post, is that the framebuffer data, and the data on the screen are one and the same. I thought for some reason that double buffering took place and the data in the framebuffer got copied onto the screen, so I could just skip the showing to the screen step.

Anyway, this thread can probably die now.
-SD

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.