Billboard objects not behaving as I would define billboard
by David Wyand · in Torque Game Engine · 03/08/2002 (10:55 am) · 11 replies
Greetings!
I just recently got my LightWave DTS Exporter to output objects with the billboard flag set. I then went and added this object to a map to test it out. It works, but not how I would define as billboard.
It would appear that a billboarded object will always maintain its orientation with the camera plane rather than pointing towards the player.
Too see this in action, load up a billboard object in a map and run the player next to it. Go to a 3rd person view, and then rotate around without moving. You'll notice that the billboarded object will rotate with the player.
If you'd like to test this out, here is my billboard object:
Billboard DTS File
Place this in your torque\example\fps\data\shapes directory tree, and then add it to your map as a static object. For those that are interested, this is a BollboardZ object.
I personally define a billboard object as one that always points to the player, and is not controlled by the camera plane. ie: the object orients itself to point towards the camera, but not rotate with the camera.
Am I bonkers here or what?
- LightWave Dave
I just recently got my LightWave DTS Exporter to output objects with the billboard flag set. I then went and added this object to a map to test it out. It works, but not how I would define as billboard.
It would appear that a billboarded object will always maintain its orientation with the camera plane rather than pointing towards the player.
Too see this in action, load up a billboard object in a map and run the player next to it. Go to a 3rd person view, and then rotate around without moving. You'll notice that the billboarded object will rotate with the player.
If you'd like to test this out, here is my billboard object:
Billboard DTS File
Place this in your torque\example\fps\data\shapes directory tree, and then add it to your map as a static object. For those that are interested, this is a BollboardZ object.
I personally define a billboard object as one that always points to the player, and is not controlled by the camera plane. ie: the object orients itself to point towards the camera, but not rotate with the camera.
Am I bonkers here or what?
- LightWave Dave
About the author
A long time Associate of the GarageGames' community and author of the Torque 3D Game Development Cookbook. Buy it today from Packt Publishing!
#2
If you extrapolate otherwise, what is the 'right' player in a multiplayer game for picking a billboard direction? ;)
d
03/08/2002 (9:17 pm)
hmm, I was pretty sure by definition a billboard is something always 'facing the camera'. The player model has little to do with it. It's a 'visual trick' so that whereever the camera is pointing, the billboards always face the right way.If you extrapolate otherwise, what is the 'right' player in a multiplayer game for picking a billboard direction? ;)
d
#3
David, I would agree with you. Perhaps my use of player is a little confusing.
To redefine my above definition: A billboard always rotates to face the camera. Using this definition, if the camera changes position, then the billboard rotates to maintain its facing. If the camera is stationary and rotates on the spot, the billboard will not move.
Now, what I am seeing in Torque, is that the billboard rotates to the same facing as the camera's projection plane. So, if the camera is stationary and rotates on the spot, the billboard will also rotate. This should not occur according to my definition above. I do not think of this as a normal billboard object.
Am I making any sense? If not, I'll try to come up with a visual example. Or do people just feel that my definition of a billboard object is wrong?
Brian, it is good to hear that particles are working as I would expect. However, I'm not sure why we would want a DTS object to behave differently (hence my concern).
- LightWave Dave
03/08/2002 (10:41 pm)
Greetings!David, I would agree with you. Perhaps my use of player is a little confusing.
To redefine my above definition: A billboard always rotates to face the camera. Using this definition, if the camera changes position, then the billboard rotates to maintain its facing. If the camera is stationary and rotates on the spot, the billboard will not move.
Now, what I am seeing in Torque, is that the billboard rotates to the same facing as the camera's projection plane. So, if the camera is stationary and rotates on the spot, the billboard will also rotate. This should not occur according to my definition above. I do not think of this as a normal billboard object.
Am I making any sense? If not, I'll try to come up with a visual example. Or do people just feel that my definition of a billboard object is wrong?
Brian, it is good to hear that particles are working as I would expect. However, I'm not sure why we would want a DTS object to behave differently (hence my concern).
- LightWave Dave
#4
The other is parallel to the normal from the line of sight of the player.
I agree with you that it should be the first one, but I'm no modeler so I couldn't really tell you if this was a problem with your exporting, the exporter, or the engine. Has everyone else experienced the same problem?
03/08/2002 (11:55 pm)
The difference he's distinguishing is that one siutation turns the billboard to be parallel to the normal from the location of the player.The other is parallel to the normal from the line of sight of the player.
I agree with you that it should be the first one, but I'm no modeler so I couldn't really tell you if this was a problem with your exporting, the exporter, or the engine. Has everyone else experienced the same problem?
#5
Yes Matt, that is a good way of putting it.
As for the exporter or exported model: To have an object become a billboard, all the DTS format requires is a flag to be set. It is the engine itself that decides what to do with this flag, so there is no billboard code built into the object itself.
However, if someone would like to try out my test above with my object and perhaps one from Max/MilkShape, I sure would like to know if the results are the same. If they are, then we can discuss if this particular behaviour is what should be expected from a billboard object.
Heck, if someone can produce a BillboardZ object from Max, I’ll test it out myself and let you know what I find at no extra charge :o)
- LightWave Dave
03/09/2002 (12:59 pm)
Greetings!Yes Matt, that is a good way of putting it.
As for the exporter or exported model: To have an object become a billboard, all the DTS format requires is a flag to be set. It is the engine itself that decides what to do with this flag, so there is no billboard code built into the object itself.
However, if someone would like to try out my test above with my object and perhaps one from Max/MilkShape, I sure would like to know if the results are the same. If they are, then we can discuss if this particular behaviour is what should be expected from a billboard object.
Heck, if someone can produce a BillboardZ object from Max, I’ll test it out myself and let you know what I find at no extra charge :o)
- LightWave Dave
#6
d
03/11/2002 (2:58 pm)
Well, I guess it could be viewed, and argued, both ways. I'm used to billboards that are always parallel to the plane of the camera. That's also become I come from a coding background that goes back to pseudo-3D engines where all objects were billboards, as drawing camera-parallel makes them always rectangles, which is simple to code. Otherwise, they are perspective-skewed quads, which rquires more difficult computations. Of course, it is rather moot with 3D chips, unless you somehow take advantage of the differences (i.e., you actually compute in software or something like that).d
#7
Well, I'll assume by the lack of interest in this topic that others would agree with your assessment David, or just don't care (other than Matt).
Admittedly, these days billboards are almost exclusively used for particle effects. And in this case, the existing behaviour works for me.
If down the road I find that I have an actual need for billboards to behave as I expected, then I'll just expand the DTS format and add some extra options to my LightWave exporter.
- LightWave Dave
03/15/2002 (6:47 am)
Greetings!Well, I'll assume by the lack of interest in this topic that others would agree with your assessment David, or just don't care (other than Matt).
Admittedly, these days billboards are almost exclusively used for particle effects. And in this case, the existing behaviour works for me.
If down the road I find that I have an actual need for billboards to behave as I expected, then I'll just expand the DTS format and add some extra options to my LightWave exporter.
- LightWave Dave
#8
03/17/2002 (10:23 am)
I agree with Matt--the billboard normal should face the player location, not the player line of sight. It's a bit disconcerting when billboard trees rotate as you pan your view; the tree actually appears narrower as your view moves away from it.
#9
I prefaced the objects with BB:: as stated in the docs, but when I export it, it doesn't face the camera, it faces directly up/down (flat) and does some strange rotation behaviour.
Any clues on what I'm doing wrong? I scanned the forums and noted some discussion on BillboardZs having a bug, but not spcifically the Billboard.
11/27/2005 (9:10 am)
I'm having trouble exporting a billboard object (I've never done it before)..I prefaced the objects with BB:: as stated in the docs, but when I export it, it doesn't face the camera, it faces directly up/down (flat) and does some strange rotation behaviour.
Any clues on what I'm doing wrong? I scanned the forums and noted some discussion on BillboardZs having a bug, but not spcifically the Billboard.
#10
It's not really a bug, just a non-intuitive convention.
11/27/2005 (11:15 am)
The issue is that the mesh is getting exported with the wrong axis alignment so when Torque tries to align it to the camera it shows up rotated. Basically you have to make sure it is rotated properly relative to its pivot point, if my understanding of how Max works isn't totally flawed. ;) It's a trivial thing, but I don't know exactly how to fix it as I'm a coder.It's not really a bug, just a non-intuitive convention.
#11
Aha! (for those after me) - The pivot point of the bounding box is irrelevant here. I set the pivots on the actual billboarded objcts to Red-Right Green-Forward Blue-Up and they faced the camera properly.
My new problem is animation. You can't have a billboarded object as an item, because the "automatic rotation" of items won't shut off and does wierd thing. As a StaticShape, you get collisions and it billboards correctly, but I'm having trouble triggering the animation on the billboard item. Does anybody know how to do this?
11/27/2005 (3:32 pm)
I made the pivot-point red-right green-forward blue-up as is stated in the docs.. but I could experiment with othersAha! (for those after me) - The pivot point of the bounding box is irrelevant here. I set the pivots on the actual billboarded objcts to Red-Right Green-Forward Blue-Up and they faced the camera properly.
My new problem is animation. You can't have a billboarded object as an item, because the "automatic rotation" of items won't shut off and does wierd thing. As a StaticShape, you get collisions and it billboards correctly, but I'm having trouble triggering the animation on the billboard item. Does anybody know how to do this?
Torque Owner Brian Wells