X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;ds=sidebyside;f=blender%2Fio_mspgl%2Fexport_scene.py;h=0ad6769f1dedb0daa1230aa131d0fed229f11db2;hb=006bdb4f8660098fc524dcca80b24c943c65b249;hp=77755a65b7479353958f36ebee02c8f77635a1bd;hpb=7d8c187f036a7c91f9073ca0071a20807c0f1aa5;p=libs%2Fgl.git diff --git a/blender/io_mspgl/export_scene.py b/blender/io_mspgl/export_scene.py index 77755a65..0ad6769f 100644 --- a/blender/io_mspgl/export_scene.py +++ b/blender/io_mspgl/export_scene.py @@ -108,7 +108,7 @@ class SceneExporter: resources[lighting_name] = lighting_res def export_sequence(self, scene, resources): - from .datafile import Resource, Statement + from .datafile import Resource, Statement, Token seq_res = Resource(scene.name+".seq", "sequence") if scene.use_hdr: @@ -118,12 +118,23 @@ class SceneExporter: if scene.background_set: content = resources[scene.name+".wrapper.scene"] - ss = Statement("pass", "", "content") - ss.sub.append(Statement("depth_test", "lequal")) + ss = Statement("clear") + ss.sub.append(Statement("color", 0.0, 0.0, 0.0, 0.0)) + ss.sub.append(Statement("depth", 1.0)) + seq_res.statements.append(ss) + + ss = Statement("step", "", "content") + ss.sub.append(Statement("depth_test", Token("LEQUAL"))) ss.sub.append(seq_res.create_reference_statement("lighting", resources[scene.name+".lightn"])) ss.sub.append(seq_res.create_reference_statement("scene", content)) seq_res.statements.append(ss) + if scene.use_ao: + ss = Statement("ambient_occlusion") + ss.sub.append(Statement("occlusion_radius", scene.ao_distance)) + ss.sub.append(Statement("samples", scene.ao_samples)) + seq_res.statements.append(ss) + if scene.use_hdr: seq_res.statements.append(Statement("bloom")) ss = Statement("colorcurve")