Implemented some more overlay support - the overlay bitmap is now allocated

via the graphics driver (but not yet shown on screen).
I probably got the meaning of the "overlay count" wrong - I guess that you
can allocate any number of overlay bitmaps, but can only see "overlay count"
on screen at a time (right now, I only allow to create "overlay count" bitmaps).
Stephan?


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17193 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2006-04-21 20:14:41 +00:00
parent 2e16ba2acc
commit 37b502f28b
13 changed files with 288 additions and 56 deletions
+5 -10
View File
@@ -928,12 +928,12 @@ BBitmap::_InitObject(BRect bounds, color_space colorSpace, uint32 flags,
int8 allocationType;
link.Read<int8>(&allocationType);
if (allocationType == kArea) {
// TODO: implement me (server-side as well), needed for overlays
if (allocationType == kFramebuffer) {
link.Read<addr_t>((addr_t*)&fBasePointer);
link.Read<int32>(&fBytesPerRow);
fServerArea = B_ERROR;
fAreaOffset = -1;
// that signals the cleanup code to delete our area
fBasePointer = NULL;
fAreaOffset = 0;
} else {
link.Read<area_id>(&fServerArea);
link.Read<int32>(&fAreaOffset);
@@ -1012,11 +1012,6 @@ BBitmap::_CleanUp()
// TODO: we may want to delete parts of the server memory areas here!
if (fAreaOffset == -1) {
// we own that area, so we have to delete it
delete_area(fArea);
}
fArea = -1;
fServerToken = -1;
fAreaOffset = -1;