public interface JCGLBlendingType
Modifier and Type | Method and Description |
---|---|
void |
blendingDisable()
Disable blending.
|
default void |
blendingEnable(JCGLBlendFunction source_factor,
JCGLBlendFunction destination_factor)
Enable blending with the given blending functions.
|
default void |
blendingEnableSeparate(JCGLBlendFunction source_rgb_factor,
JCGLBlendFunction source_alpha_factor,
JCGLBlendFunction destination_rgb_factor,
JCGLBlendFunction destination_alpha_factor)
Enable blending with the given blending functions.
|
void |
blendingEnableSeparateWithEquationSeparate(JCGLBlendFunction source_rgb_factor,
JCGLBlendFunction source_alpha_factor,
JCGLBlendFunction destination_rgb_factor,
JCGLBlendFunction destination_alpha_factor,
JCGLBlendEquation equation_rgb,
JCGLBlendEquation equation_alpha)
Enable blending with the blending functions
source_rgb_factor ,
source_alpha_factor , destination_rgb_factor , and destination_alphafactor . |
default void |
blendingEnableWithEquation(JCGLBlendFunction source_factor,
JCGLBlendFunction destination_factor,
JCGLBlendEquation equation)
Enable blending with the given blending functions and equation.
|
default void |
blendingEnableWithEquationSeparate(JCGLBlendFunction source_factor,
JCGLBlendFunction destination_factor,
JCGLBlendEquation equation_rgb,
JCGLBlendEquation equation_alpha)
Enable blending with the given blending functions and equation.
|
boolean |
blendingIsEnabled() |
void blendingDisable() throws JCGLException
JCGLException
- Iff an OpenGL error occursboolean blendingIsEnabled() throws JCGLException
true
iff blending is enabledJCGLException
- Iff an OpenGL error occursdefault void blendingEnable(JCGLBlendFunction source_factor, JCGLBlendFunction destination_factor) throws JCGLException, JCGLExceptionBlendingMisconfigured
{@link JCGLBlendingType#blendingEnableSeparateWithEquationSeparate}(
source_factor, source_factor, destination_factor, destination_factor,
JCGLBlendEquation.BLEND_EQUATION_ADD, JCGLBlendEquation
.BLEND_EQUATION_ADD);
source_factor
- The source factordestination_factor
- The destination factorJCGLException
- Iff an OpenGL error occursJCGLExceptionBlendingMisconfigured
- Iff the combination of blending
parameters is invaliddefault void blendingEnableSeparate(JCGLBlendFunction source_rgb_factor, JCGLBlendFunction source_alpha_factor, JCGLBlendFunction destination_rgb_factor, JCGLBlendFunction destination_alpha_factor) throws JCGLException, JCGLExceptionBlendingMisconfigured
{@link JCGLBlendingType#blendingEnableSeparateWithEquationSeparate}(
source_rgb_factor, source_alpha_factor, destination_rgb_factor,
destination_alpha_factor, JCGLBlendEquation.BLEND_EQUATION_ADD,
JCGLBlendEquation.BLEND_EQUATION_ADD);
source_rgb_factor
- The function used to blend the RGB
components of incoming (source) color
valuessource_alpha_factor
- The function used to blend the alpha
components of incoming (source) color
valuesdestination_rgb_factor
- The function used to blend the RGB
components of the existing (destination)
color valuesdestination_alpha_factor
- The function used to blend the alpha
components of the existing (destination)
color valuesJCGLException
- Iff an OpenGL error occursJCGLExceptionBlendingMisconfigured
- Iff the combination of blending
parameters is invalidvoid blendingEnableSeparateWithEquationSeparate(JCGLBlendFunction source_rgb_factor, JCGLBlendFunction source_alpha_factor, JCGLBlendFunction destination_rgb_factor, JCGLBlendFunction destination_alpha_factor, JCGLBlendEquation equation_rgb, JCGLBlendEquation equation_alpha) throws JCGLException, JCGLExceptionBlendingMisconfigured
Enable blending with the blending functions source_rgb_factor
,
source_alpha_factor
, destination_rgb_factor
, and destination_alphafactor
. The OpenGL defaults are BLEND_ONE
for
source_rgb_factor
and source_alpha_factor
, and BLEND_ZERO
, for and destination_rgb_factor
and destination_alpha_factor
, respectively.
The given blend functions are applied to the RGB and alpha elements of
the colors in question separately (as opposed to blendingEnable(com.io7m.jcanephora.core.JCGLBlendFunction, com.io7m.jcanephora.core.JCGLBlendFunction)
, which applies the given functions to the
RGB and alpha components simultaneously).
The given blend equations equation_rgb
and equation_alpha
determine how an incoming pixel is blended with the
corresponding pixel in the framebuffer. The OpenGL default is BLEND_EQUATION_ADD
for both equations.
This is the most general form of blending specification, and the other methods in the interface are defined in terms of this one.
source_rgb_factor
- The function used to blend the RGB
components of incoming (source) color
valuessource_alpha_factor
- The function used to blend the alpha
components of incoming (source) color
valuesdestination_rgb_factor
- The function used to blend the RGB
components of the existing (destination)
color valuesdestination_alpha_factor
- The function used to blend the alpha
components of the existing (destination)
color valuesequation_rgb
- The equation used to blend the RGB
componentsequation_alpha
- The equation used to blend the alpha
componentsJCGLException
- Iff an OpenGL error occursJCGLExceptionBlendingMisconfigured
- Iff the combination of blending
parameters is invaliddefault void blendingEnableWithEquation(JCGLBlendFunction source_factor, JCGLBlendFunction destination_factor, JCGLBlendEquation equation) throws JCGLException, JCGLExceptionBlendingMisconfigured
{@link JCGLBlendingType#blendingEnableSeparateWithEquationSeparate}(
source_factor, source_factor, destination_factor, destination_factor,
equation, equation);
source_factor
- The source factordestination_factor
- The destination factorequation
- The blend equationJCGLException
- Iff an OpenGL error occursJCGLExceptionBlendingMisconfigured
- Iff the combination of blending
parameters is invaliddefault void blendingEnableWithEquationSeparate(JCGLBlendFunction source_factor, JCGLBlendFunction destination_factor, JCGLBlendEquation equation_rgb, JCGLBlendEquation equation_alpha) throws JCGLException, JCGLExceptionBlendingMisconfigured
{@link JCGLBlendingType#blendingEnableSeparateWithEquationSeparate}(
source_factor, source_factor, destination_factor, destination_factor,
equation_rgb, equation_alpha);
source_factor
- The source factordestination_factor
- The destination factorequation_rgb
- The blend equation for the RGB componentsequation_alpha
- The blend equation for the alpha componentsJCGLException
- Iff an OpenGL error occursJCGLExceptionBlendingMisconfigured
- Iff the combination of blending
parameters is invalidCopyright © 2017 <code@io7m.com> http://io7m.com