def get_params(self, context): params = ParamSet() if hasattr(context, '%s_usetexture' % self.attr) \ and getattr(context, '%s_usetexture' % self.attr) and getattr(context, '%s_texturename' % self.attr): params.add_reference( 'texture', self.attr, getattr(context, '%s_texturename' % self.attr)) else: params.add_float(self.attr, getattr(context, self.attr)) return params
def get_params(self, context): params = ParamSet() if hasattr(context, '%s_usetexture' % self.attr) \ and getattr(context, '%s_usetexture' % self.attr) and getattr(context, '%s_texturename' % self.attr): params.add_reference('texture', self.attr, getattr(context, '%s_texturename' % self.attr)) else: params.add_float( self.attr, getattr(context, self.attr) ) return params
def get_params(self, context): params = ParamSet() if hasattr(context, '%s_usetexture' % self.attr) \ and getattr(context, '%s_usetexture' % self.attr) and getattr(context, '%s_texturename' % self.attr): params.add_reference('texture', 'specularTransmittance', getattr(context, '%s_texturename' % self.attr)) else: params.add_color( 'specularTransmittance', getattr(context, '%s_color' % self.attr) ) return params
def get_params(self, context): params = ParamSet() params.add_reference('texture', self.attr, getattr(context, '%s_texturename' % self.attr)) return params