Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
149 user(s) are online (112 user(s) are browsing Forums)

Members: 1
Guests: 148

TheMagicSN, more...

Support us!

Headlines

 
  Register To Post  

BltBitMap() bug in OS4.1
Home away from home
Home away from home


See User information
I found a slightly obscure bug in OS4.1 update 2 on my Sam440.

The (latest OS4.1!) SDK says this about BltBitMap():
Quote:
- as a special case, if a plane pointer in the SrcBitMap is zero, it acts as a pointer to a plane of all zeros, and if the plane pointer is 0xffffffff, it acts as a pointer to a plane of all ones. (Note: new for V36)


And this does work as expected, when the minterm is 0xC0 (i.e. copy). But when the minterm is 0x80 (i.e. logical AND) then BltBitMap() behaves as if the minterm was actually 0xC0. I suspect it completely ignores the provided minterm, and always behaves as if the minterm was 0xC0.

Note that in my code both the source & destination bitmaps have a depth of 1 bitplane, and that the (destination) plane is allocated from the heap (rather than video memory). And note that my code behaves correctly if I replace the 0xffffffff plane pointer with a real plane that has all bits set to 1.

IMHO the easiest work-around would be for OS4 to temporarily allocate a real plane (of appropriate size & content) when it finds an 0xffffffff or 0x0 plane pointer & the minterm is not 0xC0. Of course it would be nice if OS4 also efficiently implemented a few more special cases (such as logical AND & OR minterms).

Author of the PortablE programming language.
Go to top

  Register To Post

 




Currently Active Users Viewing This Thread: 1 ( 0 members and 1 Anonymous Users )




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project