Texture Mapping and colorpict usage

Hallo and thanks for the answers.

First @Giugi I did it exactly like you said:

  1. I calculated the ratio
#getinfo -d solarcell_pattern.pic | rcalc -e "$1=$5/$3" -> 0.604747162
#ratio needs to be bigger then one 
#-> ratio = 1/0.604747162 = 1.653583618
  1. I set the parameters in the following way
Ru = 1, Rv = 1.653583618
Tu,v = 0
Su,v = 1 

void colorpict solarcell_pattern
7 red green blue solarcell_pattern.pic . A1*((Lu-A3)/A5-floor((Lu-A3)/A5)) A2*((Lv-A4)/A6-floor((Lv-A4)/A6))
0
6 1 1.653583618 0 0 1 1
# Ru Rv Tu Tv Su Sv
  1. I created the mesh with obj2mesh and then generated the picture. But the result was not the result I wanted .

I put the files I used to generate this picture in Dropbox - Radiance - UV-Mapping - Simplify your life.

I also looked at your example but when I render your files with rad the result is a totall yellow box. Is that what you wanted?

And I now understand the advantages of local coordinates but my problem is that I’ve got a obj-File with hundreds of rectangles with diffrent orientations and with addiational code I can calculate those orientations. This is why I wanted to know how I can do everything manually. And I’m still not quite sure how to realise:

It would be better to have your materials defined in your object file

@Greg_Ward

Greeting Philip

I think the issue is that you obj has not UV maps then when you run obj2mesh there is not a UV to refer to…
see here: (you need ‘vt’ points)

Blender v2.90.1 OBJ File: ‘’

www.blender.org

mtllib solarcell.mtl
o Cube
v 0.820000 0.496000 0.010000
v 0.820000 0.496000 -0.010000
v 0.820000 -0.496000 0.010000
v 0.820000 -0.496000 -0.010000
v -0.820000 0.496000 0.010000
v -0.820000 0.496000 -0.010000
v -0.820000 -0.496000 0.010000
v -0.820000 -0.496000 -0.010000
vt 0.625000 0.500000
vt 0.875000 0.500000
vt 0.875000 0.750000
vt 0.625000 0.750000
vt 0.375000 0.750000
vt 0.625000 1.000000
vt 0.375000 1.000000
vt 0.375000 0.000000
vt 0.625000 0.000000
vt 0.625000 0.250000
vt 0.375000 0.250000
vt 0.125000 0.500000
vt 0.375000 0.500000
vt 0.125000 0.750000
vn 0.0000 0.0000 1.0000
vn 0.0000 -1.0000 0.0000
vn -1.0000 0.0000 0.0000
vn 0.0000 0.0000 -1.0000
vn 1.0000 0.0000 0.0000
vn 0.0000 1.0000 0.0000
usemtl solarcell
s off
f 1/1/1 5/2/1 7/3/1 3/4/1
f 4/5/2 3/4/2 7/6/2 8/7/2
f 8/8/3 7/9/3 5/10/3 6/11/3
f 6/12/4 2/13/4 4/5/4 8/14/4
f 2/13/5 1/1/5 3/4/5 4/5/5
f 6/11/6 5/10/6 1/1/6 2/13/6