billboard
-
- Posts: 13
- Joined: Wed Oct 03, 2007 9:00 am
- Location: Milano, Italia
billboard
how can i set a billboard with a part of a texture instead of the full texture?
depends on what you want...
in general you have to use a texture with dimensions in power of 2 (2^n) !!!
1st do you have such a texture and only one smaller billboard in it, or
2nd do you have such a texture with many billboards in it ???
in 1st case you can make the unused area simply transparent...
in 2nd case you can create a new texture "on the fly" and copy the wanted part from the other texture to it (probably then go to 1st case)...
for copy texture parts, there are threads in the forum, for sure...
in general you have to use a texture with dimensions in power of 2 (2^n) !!!
1st do you have such a texture and only one smaller billboard in it, or
2nd do you have such a texture with many billboards in it ???
in 1st case you can make the unused area simply transparent...
in 2nd case you can create a new texture "on the fly" and copy the wanted part from the other texture to it (probably then go to 1st case)...
for copy texture parts, there are threads in the forum, for sure...
while(!asleep) sheep++;
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
-
- Posts: 13
- Joined: Wed Oct 03, 2007 9:00 am
- Location: Milano, Italia
-
- Admin
- Posts: 3590
- Joined: Mon Oct 09, 2006 9:36 am
- Location: Scotland - gonnae no slag aff mah Engleesh
- Contact:
Sure, but IBillboardSceneNode doesn't have any methods that expose the UVs. It would be handy if it did, and while we're at it, it could really do with supporting axis alignment as well.hybrid wrote:I would change texture coords, it's pretty simple to get only a small part from the whole texture then. And it's only four vertices, so four texture coords.
Ah, rather than talk about it, I'll just do it.
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
-
- Posts: 13
- Joined: Wed Oct 03, 2007 9:00 am
- Location: Milano, Italia
-
- Admin
- Posts: 3590
- Joined: Mon Oct 09, 2006 9:36 am
- Location: Scotland - gonnae no slag aff mah Engleesh
- Contact:
It rotted, and my whims have changed anyway; I've extended the IBillboardSceneNode instead.hybrid wrote:Isn't there an axis aligned billboard patch available which is scheduled for Irrlicht 1.5
Patch uploaded, ready for the laugh test. Example 12, TerrainRendering, demonstrates the new functionality.
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way