diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-12-19 11:53:20 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-12-19 11:53:20 +0400 |
commit | 1137323a10d2330c0230103b75280e396f944b7e (patch) | |
tree | a82fc91559b116052a22949d6a4219f359217d3a /io_scene_x3d/export_x3d.py | |
parent | f705507e85fa59b7643bd30295d8b8b9b566d104 (diff) |
add missing route command for H3D export, I wasnt able to get this working but I think it _should_ work, needs further investigation.
Diffstat (limited to 'io_scene_x3d/export_x3d.py')
-rw-r--r-- | io_scene_x3d/export_x3d.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/io_scene_x3d/export_x3d.py b/io_scene_x3d/export_x3d.py index babf592e..51b66b5a 100644 --- a/io_scene_x3d/export_x3d.py +++ b/io_scene_x3d/export_x3d.py @@ -1155,8 +1155,12 @@ def export(file, # must be updated dynamically # TODO, write out 'viewpointMatrices.py' value = ' '.join(['%.6f' % f for v in mathutils.Matrix() for f in v]) - field_descr = " <!--- Object View Matrix '%s' -->" % obj.name + field_descr = " <!--- Object View Matrix Inverse '%s' -->" % obj.name fw('%s<field name="%s" type="SFMatrix4f" accessType="inputOutput" value="%s" />%s\n' % (ident, uniform['varname'], value, field_descr)) + + h3d_material_route.append( + '<ROUTE fromNode="%s" fromField="glModelViewMatrixInverse" toNode=%s toField="%s" />%s' % + (H3D_TOP_LEVEL, material_id, uniform['varname'], field_descr)) else: assert(0) |