Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / (C++/DGDK) Running into some practical problems with image commands

Author
Message
Image All
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location: Home
Posted: 23rd Nov 2008 21:31
Firstly i'd like to point out that I did not install the Nov08 update, because of all the complaints I saw people posting in the thread. I believe I have the Dec07 version, but I'd like to know both 1) if someone knows how to deal with these problems with this version and 2) if these issues have been addressed

I can't seem to find any kind of dbSetImageColorKey() function, analogous to SET IMAGE COLORKEY. Does this exist?

dbPasteImage() apparently has only one option for transparency, which makes it ignore black pixels, and it does not acknowledge alpha transparency. Firstly, I need black pixels. Secondly, I need alpha-transparent pixels to be transparent. Is there a way to get that? As a secondary option I would just change the colorkey to 0xFFFF00FF, but I can't.

Hope someone can help me, thanks in advance.


Remember those old guys? They made epic renders, I think one of them was called DaVinci, and all they used was MS Paint. Sometimes it's just skill....
SunDawg
19
Years of Service
User Offline
Joined: 21st Dec 2004
Location: Massachusetts
Posted: 23rd Nov 2008 23:10
dbSetImageColorKey() is definitely a command. It accepts three arguments, red, green, and blue (0-255). Using that command, it will set that color to be transparent in your image. As for alpha transparency, use PNG images. You should be able to control alpha layers that way.


My site, for various stuff that I make.
Image All
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location: Home
Posted: 23rd Nov 2008 23:26 Edited at: 23rd Nov 2008 23:26
Oh snap, that makes sense to use PNGs. I'm using the same memblock techniques to split up a spritesheet as I was in my Bitmap Font engine, but this time the sprite really IS a bitmap (24-bit bitmap as MSPaint saves), and I forgot that my Font was actually a PNG. I guess since it's a 24-bit format, it doesn't have an alpha channel to acknowledge.

Thanks for the suggestion


Remember those old guys? They made epic renders, I think one of them was called DaVinci, and all they used was MS Paint. Sometimes it's just skill....

Login to post a reply

Server time is: 2024-09-30 11:34:07
Your offset time is: 2024-09-30 11:34:07