v0.7.4b: Initial LibGDX commit! more details below:
Large sections of game logic are now working through libgdx instead of android libraries. There is still work to do but this is the first major step. Big changes include: - Graphics code is now through LibGDX (except for text rendering) - Initialization and screen-handling logic is now mostly through LibGDX - Audio is now through LibGDX - Input handling is now through LibGDX - Most misc functions are now through LibGDX
This commit is contained in:
@@ -21,7 +21,7 @@
|
||||
|
||||
package com.watabou.glwrap;
|
||||
|
||||
import android.opengl.GLES20;
|
||||
import com.badlogic.gdx.Gdx;
|
||||
|
||||
import javax.microedition.khronos.opengles.GL10;
|
||||
|
||||
@@ -33,21 +33,21 @@ public class Blending {
|
||||
}
|
||||
|
||||
public static void enable(){
|
||||
GLES20.glEnable( GL10.GL_BLEND );
|
||||
Gdx.gl.glEnable( GL10.GL_BLEND );
|
||||
}
|
||||
|
||||
public static void disable(){
|
||||
GLES20.glDisable( GL10.GL_BLEND );
|
||||
Gdx.gl.glDisable( GL10.GL_BLEND );
|
||||
}
|
||||
|
||||
//in this mode colors overwrite eachother, based on alpha value
|
||||
public static void setNormalMode(){
|
||||
GLES20.glBlendFunc( GL10.GL_SRC_ALPHA, GL10.GL_ONE_MINUS_SRC_ALPHA );
|
||||
Gdx.gl.glBlendFunc( GL10.GL_SRC_ALPHA, GL10.GL_ONE_MINUS_SRC_ALPHA );
|
||||
}
|
||||
|
||||
//in this mode colors add to eachother, eventually reaching pure white
|
||||
public static void setLightMode(){
|
||||
GLES20.glBlendFunc( GL10.GL_SRC_ALPHA, GL10.GL_ONE );
|
||||
Gdx.gl.glBlendFunc( GL10.GL_SRC_ALPHA, GL10.GL_ONE );
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user