[Radiance-general] Re: obj2mesh and materials

Greg Ward [email protected]
Sun, 13 Jul 2003 22:05:06 -0700


Hi Bob,

> From: bob coyne <[email protected]>
> Date: Sun Jul 13, 2003  9:24:36  PM US/Pacific
> To: [email protected]
>
> I figured out the problem...I put the "-a <materialfile>" option
> after the input .obj file rather than before it.   It didn't complain, 
> and I didn't
> notice.
>
> I switched them around and it works.  Sorry for the false alarm.

This is really a bug, which I've now fixed.  You should generally 
expect Radiance programs to check the command-line arguments for gross 
errors, but it doesn't really do so consistently.

> One other question.  Is there a way to override the values
> of materials on individual groups in meshes?  I'd like to override
> them individually from the outside so separate instances can have
> different attributes.  I don't want to have to create new meshes just
> to change some materials on groups.

Just like octree instances, the only way to substitute materials is 
wholesale.  You can't control individual groups that have been compiled 
into a mesh; you can only replace the mesh materials with one material 
that covers all objects in that mesh, and you do this by specifying a 
material modifier to the "mesh" primitive (rather than using "void").  
If you want to control materials in mesh groups, which I agree is a 
perfectly reasonable thing to want to do, you must break your groups 
into individual .OBJ files and convert them one by one with obj2mesh, 
reassembling them with an appropriate set of "mesh" primitives, whose 
materials you may then control.

-Greg