ISET / iset3d-v3

LEGACY: Replaced by iset3d (v4) -- Read a PBRT file. Edit the parameters. Render an ISET scene or optical image.
MIT License
36 stars 8 forks source link

piMaterialLib #34

Open DavidBrainard opened 3 years ago

DavidBrainard commented 3 years ago

In going through updating tutorials on the materials branch, I am stuck with t_piIntro_material_color.

I updated piMaterialAssign's call to piMaterialFind, changing idx = piMaterialFind(thisR, 'name', materialName); to idx = piMaterialFind(thisR.materials.list, 'name', materialName); which I think is right.

But the format of the materials in thisR.materials.lib (from the simple scene) appears out of date, which is causing troubles. This may have its origin with piMaterialLib, which returns a list of materials that also appear to have the old format.

I am not sure what the right fix is. Maybe just updating piMaterialLib would do it.

It's also possible that the problem is that the tutorial is trying to do things in an old way that should be more completely overhauled.