GLBasic forum

Main forum => GLBasic - en => Topic started by: pinete on 2010-Oct-17

Title: sprite draw with alpha questions
Post by: pinete on 2010-Oct-17
First of all a great "hello!" for everyone as this is my first message in the forum.
The reason I write this post is just to be informed if somebody knows if there is planned an update of the current approach of drawing mode for sprites.
Basically it seems weird to me that at default a PNG is not drawed with alpha, being required to put inmediatly before the command "Alphamode -.999", even without official documentation to make the thing work.
It's just me or it's really weird?
BTW I seize this post to ask if there exist any incompatibility doing this with Iphone/Ipod/Ipad..
Any answers will be really appreciated.
best.
Title: Re: sprite draw with alpha questions
Post by: MrTAToad on 2010-Oct-17
PNG can have a transparency mask in it, removing the need for ALPHAMODE -0.999 or SETTRANSPARENCY.

Its usually in by default (except when using Paint).
Title: Re: sprite draw with alpha questions
Post by: pinete on 2010-Oct-17
Thank you very much Mr.TAToad,
my question is basically with regards to the fact of GLBasic doesn't assum by default a PNG always have transparency, forcing to the user to use the undocumented "alphamode -.999" to do the job.
So really what I'm looking for is not a solution as I have it ;) but a more detailed information about if someone knows if this approach will persist on time..
I come from BlitzMax and the whole thing works smooooth..
ops, and of course, if the PNG with alpha can generate any kind of problems in the Iplatforms.. :P
thanks again,
Best
Title: Re: sprite draw with alpha questions
Post by: MrTAToad on 2010-Oct-17
I've had no problems with transparencies in PNG's - I've never bothered with ALPHAMODE -0.999
Title: Re: sprite draw with alpha questions
Post by: pinete on 2010-Oct-17
;-)
Title: Re: sprite draw with alpha questions
Post by: ampos on 2010-Oct-17
Why -.999 and not -1?
Title: Re: sprite draw with alpha questions
Post by: Kitty Hello on 2010-Oct-18
-1 is fine.