Game Development Community

How do i put a jpeg/png image on the wall directly in world editor?

by Bipindra Shrestha · in Torque Game Engine Advanced · 03/10/2009 (5:36 pm) · 6 replies

hi,
This is my first post.
I am trying to put an image on the wall without using any other tool but I could not figure out how to do that.
I also want to put pictures using script ... is it possible?
Thanks in advance.

About the author

Recent Threads


#1
03/10/2009 (11:23 pm)
well i don't know if you can and i think it would be a pain to do it if you can. the reason i think you cant is the code for the link and where to place that image is int he 3d objects code so you would first have to look at the code for that object but then your going to have to tell it where to put that image.

i think its just allot easier to export your 3d object and then just put your images where you put your dts file. thats after to added the images to your 3d object. :P why spend hours or even days coding in your image when all it takes is 1-2 min to add your image to your 3d object then export it seems like thats the best way to go.
#2
03/10/2009 (11:26 pm)
Thanks for the reply. I got similar replies from the guys in garagegames IRC channel. I would try it out soon.
#3
03/10/2009 (11:36 pm)
There is an sgDecalProjector what take an 'image' and projects it onto a surface.
#4
03/11/2009 (7:20 am)
If you want to project a decal you could do that with a DTS model I think but it wont work for a DIF. Also you could make a flat plane and texture it, then apply a texture of the image you want and save to DTS and place in your mission. Test the sgdecal projection to DTS because I didnt test that to see if it works. DL out.
#5
03/11/2009 (10:29 am)
Just to clarify that the sgDecalProjector does indeed project onto a DIF. This is using the "glow arrow" decal found in the lighting kit folder.
i167.photobucket.com/albums/u143/heretek/torque/screenshot_002-00000.pngIt doesn't "wrap" around corners though. You can rotate the projector to make it work on walls and the ceiling also.
#6
03/11/2009 (10:51 am)
fwiw, if you're willing to open up the engine a bit it's not too hard to implement something similar to ShapeBase::setSkinName() for DIFs. this is how we let users customize the walls and other surfaces of their apartments in vSide. the core functionality of that technique is the ability to go through the DIF and replace all instances of TextureFoo with TextureBar. it has the limitation of course that if you have two surfaces both with TextureFoo, you can't change only one of them to TextureBar. (Altho from some angles this can be considered a feature)