Beispiel #1
0
    def __init__(self):
        """
        lambertShader constructor. Calls the parent OpenMayaMPx.MPxNode constructor
        and defines the Maya attribute -> Girl material parameter mapping.
        """

        OpenMayaMPx.MPxNode.__init__(self)

        # translation table for shader
        self.attributes = {}
        self.GirlType = "GirlAnisotropic"
        self.attributes['color'] = ShaderColorAttribute('color')
        self.attributes['transparency'] = ShaderColorAttribute('transparency')
        self.attributes['ambientColor'] = ShaderColorAttribute('ambientColor')
        self.attributes['incandescence'] = ShaderColorAttribute(
            'incandescence')

        self.attributes['diffuse'] = ShaderFloatAttribute('diffuse')
        self.attributes['translucence'] = ShaderFloatAttribute('translucence')
        self.attributes['translucenceDepth'] = ShaderFloatAttribute(
            'translucenceDepth')
        self.attributes['translucenceFocus'] = ShaderFloatAttribute(
            'translucenceFocus')

        self.attributes['glowIntensity'] = ShaderFloatAttribute(
            'glowIntensity')

        self.attributes['matteOpacityMode'] = ShaderEnumAttribute(
            'matteOpacityMode', self.strrMatteOpacityMode)
        self.attributes['matteOpacity'] = ShaderFloatAttribute('matteOpacity')

        self.attributes['refractions'] = ShaderBoolAttribute('refractions')
        self.attributes['chromaticAberration'] = ShaderBoolAttribute(
            'chromaticAberration')
        self.attributes['hideSource'] = ShaderBoolAttribute('hideSource')

        self.attributes['refractiveIndex'] = ShaderFloatAttribute(
            'refractiveIndex')
        self.attributes['refractionLimit'] = ShaderFloatAttribute(
            'refractionLimit')
        self.attributes['lightAbsorbance'] = ShaderFloatAttribute(
            'lightAbsorbance')
        self.attributes['surfaceThickness'] = ShaderFloatAttribute(
            'surfaceThickness')
        self.attributes['shadowAttenuation'] = ShaderFloatAttribute(
            'shadowAttenuation')

        self.attributes['angle'] = ShaderFloatAttribute('angle')
        self.attributes['spreadX'] = ShaderFloatAttribute('spreadX')
        self.attributes['spreadY'] = ShaderFloatAttribute('spreadY')
        self.attributes['roughness'] = ShaderFloatAttribute('roughness')
        self.attributes['fresnelRefractiveIndex'] = ShaderFloatAttribute(
            'fresnelRefractiveIndex')

        self.attributes['anisotropicReflectivity'] = ShaderBoolAttribute(
            'anisotropicReflectivity')
Beispiel #2
0
    def __init__(self):
        OpenMayaMPx.MPxNode.__init__(self)

        # Export attributes
        self.attributes = {}
        self.GirlType = "roughglass"
        self.attributes['Kr']         = ShaderColorAttribute('roughglassKr')
        self.attributes['Kt']         = ShaderColorAttribute('roughglassKt')
        self.attributes['uroughness'] = ShaderFloatAttribute('roughglassURoughness', reciprocal = True)
        self.attributes['vroughness'] = ShaderFloatAttribute('roughglassVRoughness', reciprocal = True)
        self.attributes['index']      = ShaderFloatAttribute('roughglassIndex')
        self.attributes['cauchyb']    = ShaderFloatAttribute('roughglassCauchyB')
Beispiel #3
0
    def __init__(self):
        OpenMayaMPx.MPxNode.__init__(self)

        # Export attributes
        self.attributes = {}
        self.GirlType = "substrate"
        self.attributes['Kd'] = ShaderColorAttribute('substrateKd')
        self.attributes['Ks'] = ShaderColorAttribute('substrateKs')
        self.attributes['uroughness'] = ShaderFloatAttribute(
            'substrateURoughness', reciprocal=True)
        self.attributes['vroughness'] = ShaderFloatAttribute(
            'substrateVRoughness', reciprocal=True)
Beispiel #4
0
    def __init__(self):
        OpenMayaMPx.MPxNode.__init__(self)

        # Export attributes
        self.attributes = {}
        self.GirlType = "shinymetal"
        self.attributes['Kr'] = ShaderColorAttribute('shinymetalKr')
        self.attributes['Ks'] = ShaderColorAttribute('shinymetalKs')
        self.attributes['uroughness'] = ShaderFloatAttribute(
            'shinymetalURoughness', reciprocal=True)
        self.attributes['vroughness'] = ShaderFloatAttribute(
            'shinymetalVRoughness', reciprocal=True)
Beispiel #5
0
    def __init__(self):
        OpenMayaMPx.MPxNode.__init__(self)

        # Export attributes
        self.attributes = {}
        self.GirlType = "plastic"
        self.attributes['Kd'] = ShaderColorAttribute('plasticKd')
        self.attributes['Ks'] = ShaderColorAttribute('plasticKs')
        self.attributes['uroughness'] = ShaderFloatAttribute(
            'plasticURoughness', reciprocal=True)
        self.attributes['vroughness'] = ShaderFloatAttribute(
            'plasticVRoughness', reciprocal=True)
Beispiel #6
0
    def __init__(self):
        """
        blinnShader constructor. Calls the parent OpenMayaMPx.MPxNode constructor
        and defines the Maya attribute -> Girl material parameter mapping.
        """
        
        OpenMayaMPx.MPxNode.__init__(self)

        # translation table for shader
        self.attributes = {}
        self.GirlType = "substrate"
        self.attributes['Ks']         = ShaderColorAttribute('specularColor')
        self.attributes['Kd']         = ShaderColorAttribute('color')
        self.attributes['uroughness'] = ShaderFloatAttribute('eccentricity', reciprocal = True)
        self.attributes['vroughness'] = ShaderFloatAttribute('specularRollOff', reciprocal = True)
         
Beispiel #7
0
    def __init__(self):
        """
        phongShader constructor. Calls the parent OpenMayaMPx.MPxNode constructor
        and defines the Maya attribute -> Girl material parameter mapping.
        """
        
        OpenMayaMPx.MPxNode.__init__(self)

        # translation table for shader
        self.attributes = {}
        self.GirlType = "plastic"
        self.attributes['Kd']         = ShaderColorAttribute('color')
        self.attributes['Ks']         = ShaderColorAttribute('specularColor')
        self.attributes['uroughness'] = ShaderFloatAttribute('cosinePower', preScale = 0.01, invert=True, reciprocal = True, postScale = 0.1)
        self.attributes['vroughness'] = ShaderFloatAttribute('cosinePower', preScale = 0.01, invert=True, reciprocal = True, postScale = 0.1)
         
Beispiel #8
0
    def __init__(self):
        OpenMayaMPx.MPxNode.__init__(self)

        # Export attributes
        self.attributes = {}
        self.GirlType = "matte"
        self.attributes['Kd'] = ShaderColorAttribute('matteKd')
        self.attributes['sigma'] = ShaderFloatAttribute('matteSigma')
Beispiel #9
0
    def __init__(self):
        OpenMayaMPx.MPxNode.__init__(self)

        # Export attributes
        self.attributes = {}
        self.GirlType = "carpaint"
        self.attributes['name'] = ShaderEnumAttribute('carpaintName',
                                                      self.nameValues)
        self.attributes['Kd'] = ShaderColorAttribute('carpaintKd')
        self.attributes['Ks1'] = ShaderColorAttribute('carpaintKs1')
        self.attributes['Ks2'] = ShaderColorAttribute('carpaintKs2')
        self.attributes['Ks3'] = ShaderColorAttribute('carpaintKs3')
        self.attributes['R1'] = ShaderFloatAttribute('carpaintR1')
        self.attributes['R2'] = ShaderFloatAttribute('carpaintR2')
        self.attributes['R3'] = ShaderFloatAttribute('carpaintR3')
        self.attributes['M1'] = ShaderFloatAttribute('carpaintM1')
        self.attributes['M2'] = ShaderFloatAttribute('carpaintM2')
        self.attributes['M3'] = ShaderFloatAttribute('carpaintM3')
Beispiel #10
0
    def __init__(self):
        OpenMayaMPx.MPxNode.__init__(self)

        # mirror
        kr = OpenMaya.MObject()  # color

        # Export attributes
        self.attributes = {}
        self.GirlType = "mirror"
        self.attributes['Kr'] = ShaderColorAttribute('mirrorKr')
Beispiel #11
0
    def __init__(self):
        """
        lambertShader constructor. Calls the parent OpenMayaMPx.MPxNode constructor
        and defines the Maya attribute -> Girl material parameter mapping.
        """

        OpenMayaMPx.MPxNode.__init__(self)

        # translation table for shader
        self.attributes = {}
        self.GirlType = "GirlSurfaceShader"

        self.attributes['outColor'] = ShaderColorAttribute('outColor')
        self.attributes['outTransparency'] = ShaderColorAttribute(
            'outTransparency')
        self.attributes['outGlowColor'] = ShaderColorAttribute('outGlowColor')
        self.attributes['outMatteOpacity'] = ShaderColorAttribute(
            'outMatteOpacity')

        self.attributes['materialAlphaGain'] = ShaderFloatAttribute(
            'materialAlphaGain')
Beispiel #12
0
    def __init__(self):
        """
        lambertShader constructor. Calls the parent OpenMayaMPx.MPxNode constructor
        and defines the Maya attribute -> Girl material parameter mapping.
        """

        OpenMayaMPx.MPxNode.__init__(self)

        # translation table for shader
        self.attributes = {}
        self.GirlType = "matte"
        self.attributes['Kd'] = ShaderColorAttribute('color')
        self.attributes['sigma'] = ShaderFloatAttribute('translucence')
Beispiel #13
0
    def __init__(self):
        """
        lambertShader constructor. Calls the parent OpenMayaMPx.MPxNode constructor
        and defines the Maya attribute -> Girl material parameter mapping.
        """

        OpenMayaMPx.MPxNode.__init__(self)

        # translation table for shader
        self.attributes = {}
        self.GirlType = "GirlLayeredShader"
        self.attributes['matteOpacityMode'] = ShaderEnumAttribute(
            'matteOpacityMode', self.strrMatteOpacityMode)
        self.attributes['matteOpacity'] = ShaderFloatAttribute('matteOpacity')

        self.attributes['hardwareColor'] = ShaderColorAttribute(
            'hardwareColor')
        self.attributes['compositingFlag'] = ShaderEnumAttribute(
            'compositingFlag', self.strrCompositingFlag)
    def __init__(self):
        """
        lambertShader constructor. Calls the parent OpenMayaMPx.MPxNode constructor
        and defines the Maya attribute -> Girl material parameter mapping.
        """

        OpenMayaMPx.MPxNode.__init__(self)

        # translation table for shader
        self.attributes = {}
        self.GirlType = "GirlUseBackground"
        self.attributes['specularColor'] = ShaderColorAttribute(
            'specularColor')
        self.attributes['reflectionLimit'] = ShaderFloatAttribute(
            'reflectionLimit')
        self.attributes['reflectivity'] = ShaderFloatAttribute('reflectivity')

        self.attributes['matteOpacityMode'] = ShaderEnumAttribute(
            'matteOpacityMode', self.strrMatteOpacityMode)
        self.attributes['matteOpacity'] = ShaderFloatAttribute('matteOpacity')