Rect transparency?

BlitzPlus Forums/BlitzPlus Beginners Area/Rect transparency?

Apollonius(Posted 2006) [#1]
Is there a way to make a drawn rectangle transparent at 50%?
(I don't wana use an image because I might want to change it's shape and such.)


CS_TBL(Posted 2006) [#2]
Not that I know of, use Blitzmax if you want to do that..


Apollonius(Posted 2006) [#3]
Any way to do it with an image then?


CS_TBL(Posted 2006) [#4]
-> Blitzmax :P

Unless we go hacky with grabbing the screen into an image, mix your new image into it and put it back on screen.. but let's not. :D


skidracer(Posted 2006) [#5]
The simplest way is to set every odd pixel in the image to the mask color:

XoXoXoXoX
oXoXoXoXo
XoXoXoXoX
oXoXoXoXo

which unless you look very close gives the effect of the image being 50% transparant.


Apollonius(Posted 2006) [#6]
lmao, no transparency, wtf, do I have to get myself an illegal copy of blitzmax because B+ can't do one of the simplest things ever? I mean come on, B+ is supposed to be able to make games not just programs, transparency is just like the drawing command...

I'd buy Blitzmax if I hadn't already bought B+. Can Blitz 3D do transparencies? Giod sorry guys I just can't belive this lol.


CS_TBL(Posted 2006) [#7]
no, you should get a legal copy :P

btw, without B+ and with Blitzmax you wouldn't have the nice event-system, since that came with maxgui (still free for B+ owners), so having B+ already isn't bad perse..


Apollonius(Posted 2006) [#8]
What do I get with BlitzMax that I don't have with B+?


CS_TBL(Posted 2006) [#9]
uh.. OOP (tho a little tad out of your league perhaps ^_^), incbin, OGL, pc/mac/linux, event-based programming with maxgui, an IDE that could've been better, longs, doubles, bytes. Pff, uh, why don't you just click on the blitzmax ad on the frontpage? :P


Apollonius(Posted 2006) [#10]
So far I've checked the demo, it's very cool, theres alot of basic things it can do that I had expected B+ to do, and more. Alpha blending(transparency?), rotations...

The only thing I have to deplore is the damn MaxGUI, we still don't have the windows xp style gui... which sucks. Since Mac's gadgets are soo cool looking.

And yes your right all that stuff is out of my league, but I gotta start somewhere. To you programming's easy to me, chinese's easier... lol, but I'll learn I like programming.


And what is it with the no buffer thing? is thta good or bad?


xlsior(Posted 2006) [#11]
What do I get with BlitzMax that I don't have with B+?


IN addition to what CS_TBL mentioned, you also get 2D-in-3D, meaning you can do real time alpha transparancy, zooming, rotating, etc.

The only thing I have to deplore is the damn MaxGUI, we still don't have the windows xp style gui... which sucks


...Except you can get the XP look & feel by including a Manifest...


Grey Alien(Posted 2006) [#12]
There was no such thing as 3D card-based transparency in DirectX1 which Blitz Plus is based on. BlitzMax uses 3D card effects of which transparency is a function, it might seem basic to you, but it isn't, it's handled by the 3D card not the CPU.

Having said that I wrote all my own CPU-based "3D card type" effects including transparency, and posted them on this forum ... somewhere, maybe int the code archives. You need to lock buffers and do it all manually, it's a fag and slow.