Skip to content

Commit

Permalink
added Support for RSSprite
Browse files Browse the repository at this point in the history
  • Loading branch information
elmar committed Mar 30, 2020
1 parent 479b8d8 commit 3b4f409
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions python2.7libs/materialBuild_RS/eg_setupOGL.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,12 +171,22 @@ def link_textures(self):
# Normal Texture
if(i[0].inputIndex() == 49):
self.mb.parm("ogl_normalmap").set(i[0].inputNode().parm("ms_normal"), follow_parm_reference=False)
# Sprite
elif i[0].inputNode().type().name() == "redshift::Sprite":
# Diffuse Texture
if i[0].inputIndex() == 0:
self.mb.parm("ogl_diffr").set(1, follow_parm_reference=False)
self.mb.parm("ogl_diffg").set(1, follow_parm_reference=False)
self.mb.parm("ogl_diffb").set(1, follow_parm_reference=False)
self.mb.parm("ogl_tex1").set(i[0].inputNode().parm("tex0"), follow_parm_reference=False)

if i[0].inputNode().type().name() == "redshift::NormalMap":
# Normal Texture
if(i[0].inputIndex() == 49):
self.mb.parm("ogl_normalmap").set(i[0].inputNode().parm("tex0"), follow_parm_reference=False)



def link_vparm(self, target, source):
"""Link a single Vector Parm"""
self.mb.parm(target + "r").set(self.rs_mat.parm(source + "r"), follow_parm_reference=False)
Expand Down

0 comments on commit 3b4f409

Please sign in to comment.