Square Dance

Blitz3D Forums/Blitz3D Beginners Area/Square Dance

Stollentroll(Posted 2007) [#1]
Hi there!

Hello, this my first post. Maybe you could help me?



Though I have some 3D experience (Softimage, Maya and various compositing programs) and some general programming knowledge I am pretty new to Blitz3D.


I would like to do following. (Well, it could be totally stupid and there might be more elegant approach to achieve the same result. So feel free to show me a smarter way how to do it. Neverthelessm it still really would help me if you could also show me how to do it the way I intended to do.)



WHAT I WANT TO DO
-----------------
A logo flies across the screen.

The logo has no depth is not modelled, but a simpled texture put on a square or a cube with Z almost zero or a surface.
Important condition: the logo has an alpha channel. Parts of the square/cube/surface are transparent.


TWO PROBLEMS I ENCOUNTERED
--------------------------
1. What is the proper item to use? A flat cube? A pre-modelled square/quad/surface from an external 3rd party modeller (XSI, Blender or the likes)? Or could I create my "own" square in Blitz3D - and would I have to use two triangles combined to one square mesh?
What would be the best way to do this and how?


2. Can I combine two textures and how? I would like to use one texture for the color and the details of the logo and a 2nd alpha texture to "cut out" the outline. Preferably with soft edges, not simply masked out yes/no, but a grayscale image.
I did not succeed at all in combining textures. Is this possible or would I have to use 32-bit-image with an included alpha channel




(I tried to scale down a cube, but despite how small the value I entered was the cube still had some depth where the texture showed.)



It would be very nice if you could help a bloody newbie!

All the best,

Florian


boomboom(Posted 2007) [#2]
What you're after is a Sprite. Its basically a quad that will always face the camera so you don't have to worry about it rotating away.

If you save your logo as a PNG, and apply that texture onto the sprite then the alpha will be retained.

What you want todo is pretty easy, but if you ever want to deal with alot of sprites or GUI elements, then take a look at: http://www.x-pressive.com/SpriteCandy/index.html It will save you alot of time and allow you to get on with your game.


Stollentroll(Posted 2007) [#3]
Terrific, thank you! :)
That's exactly what I was looking for. I will take a deeper look at sprites.


Cheers,

Florian