> Hi,
> there are some changes wrt shader variable names are handled in code in
> the render manager branch. We're a bit unsure right now how (if) we
> preserve code compatibility. To this end I'd like to conduct a little
> survey on your use of shader variables in code (not world files etc!).
>
> So: do you manipulate SVs from code? If so, can you perhaps paste a
> small representative snippet?
>
> -f.r.
Hello,
we have one shader var manipulation from code in Ecksdee,
used to modulate ship's thruster visibility if player accelerates.
Python code init:
matw = thruster.Mesh.GetMeshObject().GetFactory().GetMaterialWrapper()
mat = matw.GetMaterial()
strings = CS_QUERY_REGISTRY_TAG_INTERFACE(oreg,
'crystalspace.shared.stringset', iStringSet)
self.shaderVars.append(mat.GetVariable(strings.Request('glow alpha')))
Then, to change thruster glow visibility:
for shadervar in self.shaderVars:
shadervar.SetValue(x)
Really a simple usage...
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Crystal-main mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/crystal-main
Unsubscribe: mailto:[EMAIL PROTECTED]