package speiger.src.coreengine.rendering.utils.values;

import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL15;

import speiger.src.coreengine.rendering.utils.values.IGLValue.IDestinationFactor;
import speiger.src.coreengine.rendering.utils.values.IGLValue.ISourceFactor;

public enum GLBlendFactor implements ISourceFactor, IDestinationFactor {
	ZERO(GL11.GL_ZERO),
	ONE(GL11.GL_ONE),
	CONSTANT_COLOR(GL15.GL_CONSTANT_COLOR),
	CONSTANT_ALPHA(GL15.GL_CONSTANT_ALPHA),
	SRC_COLOR(GL11.GL_SRC_COLOR),
	SRC_ALPHA(GL11.GL_SRC_ALPHA),
	DST_COLOR(GL11.GL_DST_COLOR),
	DST_ALPHA(GL11.GL_DST_ALPHA),
	ONE_MINUS_SRC_COLOR(GL11.GL_ONE_MINUS_SRC_COLOR),
	ONE_MINUS_SRC_ALPHA(GL11.GL_ONE_MINUS_SRC_ALPHA),
	ONE_MINUS_DST_COLOR(GL11.GL_ONE_MINUS_DST_COLOR),
	ONE_MINUS_DST_ALPHA(GL11.GL_ONE_MINUS_DST_ALPHA),
	ONE_MINUS_CONSTANT_COLOR(GL15.GL_ONE_MINUS_CONSTANT_COLOR),
	ONE_MINUS_CONSTANT_ALPHA(GL15.GL_ONE_MINUS_CONSTANT_ALPHA),
	SRC_ALPHA_SATURATE(GL11.GL_SRC_ALPHA_SATURATE);
	
	int glMode;
	
	private GLBlendFactor(int glMode) {
		this.glMode = glMode;
	}
	
	public int glValue() { return glMode; }
}
