Package com.prineside.luaj.mapping.parts
Class LJ_GDX_graphics_g3d.Shader_O.LIP
java.lang.Object
com.prineside.luaj.mapping.InterfaceProxy
com.prineside.luaj.mapping.parts.LJ_GDX_graphics_g3d.Shader_O.LIP
- All Implemented Interfaces:
com.badlogic.gdx.graphics.g3d.Shader
,com.badlogic.gdx.utils.Disposable
,com.esotericsoftware.kryo.KryoSerializable
- Enclosing class:
- LJ_GDX_graphics_g3d.Shader_O
public static class LJ_GDX_graphics_g3d.Shader_O.LIP
extends InterfaceProxy
implements com.badlogic.gdx.graphics.g3d.Shader
-
Method Summary
Modifier and TypeMethodDescriptionvoid
begin
(com.badlogic.gdx.graphics.Camera p1, com.badlogic.gdx.graphics.g3d.utils.RenderContext p2) Initializes the context for exclusive rendering by this shader.boolean
canRender
(com.badlogic.gdx.graphics.g3d.Renderable p1) Checks whether this shader is intended to render theRenderable
.int
compareTo
(com.badlogic.gdx.graphics.g3d.Shader p1) Compare this shader against the other, used for sorting, light weight shaders are rendered first.void
dispose()
Releases all resources of this object.void
end()
Cleanup the context so other shaders can render.void
init()
Initializes the Shader, must be called before the Shader can be used.void
render
(com.badlogic.gdx.graphics.g3d.Renderable p1) Renders theRenderable
, must be called betweenShader.begin(Camera, RenderContext)
andShader.end()
.Methods inherited from class com.prineside.luaj.mapping.InterfaceProxy
getLuaObj, read, write
-
Method Details
-
begin
public void begin(com.badlogic.gdx.graphics.Camera p1, com.badlogic.gdx.graphics.g3d.utils.RenderContext p2) Description copied from interface:com.badlogic.gdx.graphics.g3d.Shader
Initializes the context for exclusive rendering by this shader. Use theShader.render(Renderable)
method to render aRenderable
. When done rendering theShader.end()
method must be called.- Specified by:
begin
in interfacecom.badlogic.gdx.graphics.g3d.Shader
- Parameters:
p1
- The camera to use when renderingp2
- The context to be used, which must be exclusive available for the shader until the call to theShader.end()
method.
-
canRender
public boolean canRender(com.badlogic.gdx.graphics.g3d.Renderable p1) Description copied from interface:com.badlogic.gdx.graphics.g3d.Shader
Checks whether this shader is intended to render theRenderable
. Use this to make sure a call to theShader.render(Renderable)
method will succeed. This is expected to be a fast, non-blocking method. Note that this method will only return true if it is intended to be used. Even when it returns false the Shader might still be capable of rendering, but it's not preferred to do so.- Specified by:
canRender
in interfacecom.badlogic.gdx.graphics.g3d.Shader
- Parameters:
p1
- The renderable to check against this shader.- Returns:
- true if this shader is intended to render the
Renderable
, false otherwise.
-
compareTo
public int compareTo(com.badlogic.gdx.graphics.g3d.Shader p1) Description copied from interface:com.badlogic.gdx.graphics.g3d.Shader
Compare this shader against the other, used for sorting, light weight shaders are rendered first.- Specified by:
compareTo
in interfacecom.badlogic.gdx.graphics.g3d.Shader
-
dispose
public void dispose()Description copied from interface:com.badlogic.gdx.utils.Disposable
Releases all resources of this object.- Specified by:
dispose
in interfacecom.badlogic.gdx.utils.Disposable
-
end
public void end()Description copied from interface:com.badlogic.gdx.graphics.g3d.Shader
Cleanup the context so other shaders can render. Must be called when done rendering using theShader.render(Renderable)
method, which must be preceded by a call toShader.begin(Camera, RenderContext)
. After a call to this method an call to theShader.render(Renderable)
method will fail until theShader.begin(Camera, RenderContext)
is called.- Specified by:
end
in interfacecom.badlogic.gdx.graphics.g3d.Shader
-
init
public void init()Description copied from interface:com.badlogic.gdx.graphics.g3d.Shader
Initializes the Shader, must be called before the Shader can be used. This typically compiles aShaderProgram
, fetches uniform locations and performs other preparations for usage of the Shader.- Specified by:
init
in interfacecom.badlogic.gdx.graphics.g3d.Shader
-
render
public void render(com.badlogic.gdx.graphics.g3d.Renderable p1) Description copied from interface:com.badlogic.gdx.graphics.g3d.Shader
Renders theRenderable
, must be called betweenShader.begin(Camera, RenderContext)
andShader.end()
. The Shader instance might not be able to render every type ofRenderable
s. Use theShader.canRender(Renderable)
method to check if the Shader is capable of rendering a specificRenderable
.- Specified by:
render
in interfacecom.badlogic.gdx.graphics.g3d.Shader
- Parameters:
p1
- The renderable to render, all required fields (e.g.Renderable.material
and others) must be set. TheRenderable.shader
field will be ignored.
-