Module imp3d

Class SideSwitchShader

All Implemented Interfaces:
Scattering, Shader, Manageable, Shareable, Scattering, Shader

public class SideSwitchShader extends SwitchShader
  • Field Details

  • Constructor Details

    • SideSwitchShader

      public SideSwitchShader()
    • SideSwitchShader

      public SideSwitchShader(Shader frontShader)
    • SideSwitchShader

      public SideSwitchShader(Shader frontShader, Shader backShader)
  • Method Details

    • getAverageColor

      public int getAverageColor()
      Description copied from interface: Scattering
      Returns an average color for the scattering entity. This color is used for simplified graphical representations of the corresponding objects.
      Returns:
      an average color in Java's default sRGB color space, encoded as an int (0xAARRGGBB).
    • getFlags

      public int getFlags()
    • getShaderFor

      protected Shader getShaderFor(Environment env, Vector3f in)
      Description copied from class: SwitchShader
      This method has to be implemented by subclasses and defines the actual shader which shall be used depending on the environment and the ray direction.
      Specified by:
      getShaderFor in class SwitchShader
      Parameters:
      env - environment for which shading computations are to be performed
      in - given ray direction
      Returns:
      actual shader to use for shading computations
    • isTransparent

      public boolean isTransparent()
      Specified by:
      isTransparent in interface Shader
      Overrides:
      isTransparent in class SwitchShader
    • setShaders

      public void setShaders(Shader front, Shader back)
    • getManageableType

      public ManageableType getManageableType()
    • getFrontShader

      public Shader getFrontShader()
    • setFrontShader

      public void setFrontShader(Shader value)
    • getBackShader

      public Shader getBackShader()
    • setBackShader

      public void setBackShader(Shader value)
    • accept

      public void accept(ShaderVisitor visitor)