[Radiance-general] obj2mesh, UV coordinates and image aspect

Francesco Anselmo francesco.anselmo at arup.com
Mon Feb 20 10:39:22 CET 2006


Hi Thomas,

If you're using the blender uv editor, try to have a look at the 
function exportRadianceMeshOBJ here:
http://cvs.savannah.nongnu.org/viewcvs/brad/brad/brad/brad_radiance.py?r
oot=brad&view=markup

I remember having similar problems and having fixed them with this
check:
w,h = img.getSize()
if w>h:
   objfile.write("vt " + str(uvco[0]*(float(w)/float(h))) + " " +
str(uvco[1]) + "\n")
else:
   objfile.write("vt " + str(uvco[0]) + " " +
str(uvco[1]*(float(h)/float(w))) + "\n")

I then use:

void colorpict facematerialbasename
7 red green blue facematerialbasename.pic . Lu Lv
0
0

Hope to have understood your problem, and that this helps.

Ciao,

F.
____________________________________________________________
Electronic mail messages entering and leaving Arup  business
systems are scanned for acceptability of content and viruses



More information about the Radiance-general mailing list