Created
December 6, 2011 02:00
-
-
Save dalinaum/1436352 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma version(1) | |
#pragma rs java_package_name(jp.flatlib.ap02) | |
#include "rs_graphics.rsh" | |
rs_mesh mesh; // class Mesh | |
rs_program_vertex vsh; // class ProgramVertex | |
rs_program_fragment psh; // class ProgramFragment | |
rs_program_store dsbstate; // class ProgramStore | |
rs_program_raster rstate; // class ProgramRaster | |
rs_sampler sampler; // class Sampler | |
rs_allocation texture; // class Allocation | |
int root() // 매 프레임 마다 호출됨 | |
{ | |
rsgClearColor( 0.5f, 0.5f, 0.0f, 0.0f ); | |
rsgBindSampler( psh, 0, sampler ); | |
rsgBindTexture( psh, 0, texture ); | |
rsgBindProgramFragment( psh ); | |
rsgBindProgramVertex( vsh ); | |
rsgBindProgramStore( dsbstate ); | |
rsgBindProgramRaster( rstate ); | |
rsgDrawMesh( mesh ); // polygon을 그린다. | |
return 33; // interval 33msec | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment