Ejemplo n.º 1
0
 public override void TakeOverParameterValue(ShaderParameter otherParameter)
 {
     if (GetParamType() == otherParameter.GetParamType())
     {
         d_parameterValue = ((ShaderParameterFloat)otherParameter).d_parameterValue;
     }
 }
Ejemplo n.º 2
0
        public override bool Equal(ShaderParameter otherParameter)
        {
            if (GetParamType() == otherParameter.GetParamType())
            {
                return(d_parameterValue == ((ShaderParameterFloat)otherParameter).d_parameterValue);
            }


            return(false);
        }
Ejemplo n.º 3
0
 /// <summary>
 /// Adds a new shader parameter to the parameter bindings. If an old one exists it will be
 /// deleted and replaced by the new one.
 /// </summary>
 /// <param name="parameter_name">
 /// The name of the parameter as used by the shader
 /// </param>
 /// <param name="shader_parameter">
 /// The pointer to the shader_parameter
 /// </param>
 protected void SetNewParameter(string parameter_name, ShaderParameter shader_parameter)
 {
     if (d_shaderParameterBindings.ContainsKey(parameter_name))
     {
         // TODO: d_shaderParameterBindings[parameter_name].Dispose(); // delete found_iterator->second;
         d_shaderParameterBindings[parameter_name] = shader_parameter;
     }
     else
     {
         d_shaderParameterBindings.Add(parameter_name, shader_parameter);
     }
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Copies the parameter value from the passed ShaderParameter to this
 /// one if the classes are of the same type.
 /// </summary>
 /// <param name="otherParameter">
 /// The ShaderParameter from which the parameter value should be taken over.
 /// </param>
 public abstract void TakeOverParameterValue(ShaderParameter otherParameter);
Ejemplo n.º 5
0
 /// <summary>
 /// Checks if the ShaderParameters are equal, depending on their type
 /// and parameter.
 /// </summary>
 /// <param name="otherParameter"></param>
 /// <returns>
 /// True if the ShaderParameters are equal.
 /// </returns>
 public abstract bool Equal(ShaderParameter otherParameter);
Ejemplo n.º 6
0
 public override void TakeOverParameterValue(ShaderParameter otherParameter)
 {
     throw new NotImplementedException();
 }
Ejemplo n.º 7
0
 public override bool Equal(ShaderParameter otherParameter)
 {
     throw new NotImplementedException();
 }