- java.lang.Object
-
- processing.opengl.PGL
-
public abstract class PGL extends Object
Processing-OpenGL abstraction layer. Needs to be implemented by subclasses using specific OpenGL-Java bindings. It includes a full GLES 2.0 interface.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static interfacePGL.FontOutlineprotected static interfacePGL.Tessellatorprotected static interfacePGL.TessellatorCallback
-
Field Summary
Fields Modifier and Type Field Description protected intactiveTexUnitstatic intALIASED_LINE_WIDTH_RANGEstatic intALIASED_POINT_SIZE_RANGEstatic intALPHAstatic intALPHA8static intALREADY_SIGNALEDstatic intALWAYSstatic intARRAY_BUFFERstatic intBACKprotected intbackTexprotected static booleanBIG_ENDIANSet to true if the host system is big endian (PowerPC, MIPS, SPARC), false if little endian (x86 Intel for Mac or PC).static intBLENDstatic intBOOLstatic intBOOL_VEC2static intBOOL_VEC3static intBOOL_VEC4protected int[][]boundTexturesstatic intBUFFER_SIZEstatic intBUFFER_USAGEstatic intBYTEprotected ByteBufferbyteBufferstatic intCCWstatic intCLAMP_TO_EDGEprotected booleanclearColorUsed to register calls to background.protected booleanclearDepthprotected booleanclearStencilprotected static int[]closeButtonPixprotected IntBuffercloseButtonTexprotected intcloseButtonYstatic intCOLOR_ATTACHMENT0static intCOLOR_ATTACHMENT1static intCOLOR_ATTACHMENT2static intCOLOR_ATTACHMENT3static intCOLOR_BUFFER_BITprotected IntBuffercolorBufferstatic intCOMPILE_STATUSstatic intCOMPRESSED_TEXTURE_FORMATSstatic intCONDITION_SATISFIEDstatic intCONSTANT_ALPHAstatic intCONSTANT_COLORstatic intCULL_FACEstatic intCURRENT_VERTEX_ATTRIBprotected floatcurrentFpsstatic intCWstatic intDECRstatic intDECR_WRAPprotected static intDEFAULT_IN_EDGESprotected static intDEFAULT_IN_TEXTURESprotected static intDEFAULT_IN_VERTICESInitial sizes for arrays of input and tessellated data.protected static intDEFAULT_TESS_INDICESprotected static intDEFAULT_TESS_VERTICESstatic intDELETE_STATUSstatic intDEPTH_ATTACHMENTstatic intDEPTH_BITSstatic intDEPTH_BUFFER_BITstatic intDEPTH_COMPONENTstatic intDEPTH_COMPONENT16static intDEPTH_COMPONENT24static intDEPTH_COMPONENT32protected static StringDEPTH_READING_NOT_ENABLED_ERRORstatic intDEPTH_STENCILstatic intDEPTH_TESTstatic intDEPTH_WRITEMASKstatic intDEPTH24_STENCIL8protected FloatBufferdepthBufferstatic intDITHERstatic intDONT_CAREstatic intDRAW_FRAMEBUFFERstatic intDST_ALPHAstatic intDST_COLORstatic intDYNAMIC_DRAWstatic intELEMENT_ARRAY_BUFFERstatic intEQUALstatic intEXTENSIONSstatic intFALSEstatic intFASTESTprotected intfboHeightprotected booleanfboLayerCreatedprotected booleanfboLayerDisableReqprotected booleanfboLayerEnabledprotected booleanfboLayerEnabledReqprotected booleanfbolayerResetReqprotected intfboWidthprotected IntBufferfirstFramestatic intFLOATprotected static floatFLOAT_EPSMachine Epsilon for float precision.static intFLOAT_MAT2static intFLOAT_MAT3static intFLOAT_MAT4static intFLOAT_VEC2static intFLOAT_VEC3static intFLOAT_VEC4protected static intFLUSH_VERTEX_COUNTCount of tessellated fill, line or point vertices that will trigger a flush in the immediate mode.static intFRAGMENT_SHADERstatic intFRAMEBUFFERstatic intFRAMEBUFFER_ATTACHMENT_OBJECT_NAMEstatic intFRAMEBUFFER_ATTACHMENT_OBJECT_TYPEstatic intFRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACEstatic intFRAMEBUFFER_ATTACHMENT_TEXTURE_LEVELstatic intFRAMEBUFFER_COMPLETEstatic StringFRAMEBUFFER_ERRORstatic intFRAMEBUFFER_INCOMPLETE_ATTACHMENTstatic intFRAMEBUFFER_INCOMPLETE_DIMENSIONSstatic intFRAMEBUFFER_INCOMPLETE_DRAW_BUFFERstatic intFRAMEBUFFER_INCOMPLETE_FORMATSstatic intFRAMEBUFFER_INCOMPLETE_LAYER_TARGETSstatic intFRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENTstatic intFRAMEBUFFER_INCOMPLETE_MULTISAMPLEstatic intFRAMEBUFFER_INCOMPLETE_READ_BUFFERstatic intFRAMEBUFFER_UNDEFINEDstatic intFRAMEBUFFER_UNSUPPORTEDstatic intFRONTstatic intFRONT_AND_BACKprotected intfrontTexstatic intFUNC_ADDstatic intFUNC_MAXstatic intFUNC_MINstatic intFUNC_REVERSE_SUBTRACTstatic intFUNC_SUBTRACTstatic intGENERATE_MIPMAP_HINTprotected intgeomCountUsed to register amount of geometry rendered in each frame.static intGEQUALprotected IntBufferglColorFboprotected IntBufferglColorTexprotected intglContextID of the GL context associated to the surfaceprotected IntBufferglDepthprotected IntBufferglDepthStencilprotected IntBufferglMultiColorprotected IntBufferglMultiDepthprotected IntBufferglMultiDepthStencilprotected IntBufferglMultiFboprotected IntBufferglMultiStencilprotected static StringGLSL_FN_REGEXprotected static StringGLSL_ID_REGEXprotected IntBufferglStencilprotected ThreadglThreadOpenGL threadprotected PGraphicsOpenGLgraphicsThe PGraphics and PApplet objects using this interfacestatic intGREATERstatic intHIGH_FLOATstatic intHIGH_INTstatic intINCRstatic intINCR_WRAPprotected static intINDEX_TYPEstatic intINFO_LOG_LENGTHstatic intINTstatic intINT_VEC2static intINT_VEC3static intINT_VEC4protected IntBufferintBufferstatic intINVERTstatic intKEEPstatic intLEQUALstatic intLESSstatic intLINE_LOOPstatic intLINE_SMOOTHstatic intLINE_STRIPstatic intLINEARstatic intLINEAR_MIPMAP_LINEARstatic intLINEAR_MIPMAP_NEARESTstatic intLINESstatic intLINK_STATUSprotected booleanloadedTex2DShaderprotected booleanloadedTexRectShaderstatic intLOW_FLOATstatic intLOW_INTstatic intLUMINANCEstatic intLUMINANCE_ALPHAprotected static intMAX_CAPS_JOINS_LENGTHMaximum length of linear paths to be stroked with the full algorithm that generates accurate caps and joins.static intMAX_COMBINED_TEXTURE_IMAGE_UNITSprotected static intMAX_FONT_TEX_SIZEprotected static intMAX_LIGHTSMaximum lights by default is 8, the minimum defined by OpenGL.static intMAX_SAMPLESstatic intMAX_TEXTURE_IMAGE_UNITSstatic intMAX_TEXTURE_MAX_ANISOTROPYstatic intMAX_TEXTURE_SIZEstatic intMAX_VERTEX_ATTRIBSprotected static intMAX_VERTEX_INDEXMaximum index value of a tessellated vertex.protected static intMAX_VERTEX_INDEX1static intMAX_VERTEX_TEXTURE_IMAGE_UNITSprotected intmaxTexUnitsUsed to keep track of which textures are bound to each targetstatic intMEDIUM_FLOATstatic intMEDIUM_INTprotected static intMIN_ARRAYCOPY_SIZEMinimum array size to use arrayCopy method().protected static floatMIN_CAPS_JOINS_WEIGHTMinimum stroke weight needed to apply the full path stroking algorithm that properly generates caps and joins.protected static intMIN_DIRECT_BUFFER_SIZEprotected static intMIN_FONT_TEX_SIZEMinimum/maximum dimensions of a texture used to hold font data.protected static booleanMIPMAPS_ENABLEDEnables/disables mipmap use.static StringMISSING_FBO_ERRORstatic StringMISSING_GLFUNC_ERRORstatic StringMISSING_GLSL_ERRORstatic intMULTISAMPLEstatic intNEARESTprotected booleanneedSepFrontTexstatic intNEVERstatic intNICESTstatic StringNONPRIMARY_ERRORstatic intNOTEQUALstatic intNUM_COMPRESSED_TEXTURE_FORMATSprotected intnumSamplesstatic intONEstatic intONE_MINUS_CONSTANT_ALPHAstatic intONE_MINUS_CONSTANT_COLORstatic intONE_MINUS_DST_COLORstatic intONE_MINUS_SRC_ALPHAstatic intONE_MINUS_SRC_COLORstatic intPACK_ALIGNMENTprotected booleanpclearColorprotected booleanpclearDepthprotected booleanpclearStencilprotected intpgeomCountstatic intPIXEL_PACK_BUFFERstatic intPOINTSstatic intPOLYGON_OFFSET_FILLstatic intPOLYGON_SMOOTHprotected booleanpresentModefloatpresentXfloatpresentYbooleanprimaryPGLtrue if this is the GL interface for a primary surface PGraphicsstatic intREAD_FRAMEBUFFERstatic intREAD_ONLYstatic intREAD_WRITEstatic intRENDERBUFFERstatic intRENDERBUFFER_ALPHA_SIZEstatic intRENDERBUFFER_BLUE_SIZEstatic intRENDERBUFFER_DEPTH_SIZEstatic intRENDERBUFFER_GREEN_SIZEstatic intRENDERBUFFER_HEIGHTstatic intRENDERBUFFER_INTERNAL_FORMATstatic intRENDERBUFFER_RED_SIZEstatic intRENDERBUFFER_STENCIL_SIZEstatic intRENDERBUFFER_WIDTHstatic intRENDERERstatic intREPEATstatic intREPLACEintreqNumSamplesstatic intREQUESTED_ALPHA_BITSstatic intREQUESTED_DEPTH_BITSstatic intREQUESTED_STENCIL_BITSstatic intRGBstatic intRGB5_A1static intRGB565static intRGB8static intRGBAstatic intRGBA4static intRGBA8static intSAMPLE_ALPHA_TO_COVERAGEstatic intSAMPLE_COVERAGEstatic intSAMPLER_2Dstatic intSAMPLER_CUBEstatic intSAMPLESstatic intSCISSOR_TESTprotected static intSEG_CLOSEprotected static intSEG_CUBICTOprotected static intSEG_LINETOprotected static intSEG_MOVETOprotected static intSEG_QUADTOprotected booleansetFpsprotected static StringSHADER_PREPROCESSOR_DIRECTIVEstatic intSHADER_SOURCE_LENGTHstatic intSHADER_TYPEstatic intSHADING_LANGUAGE_VERSIONprotected static booleanSHAPE_TEXT_SUPPORTEDstatic intSHORTprotected booleanshowStopButtonprotected static booleanSINGLE_BUFFEREDprotected static intSIZEOF_BYTEprotected static intSIZEOF_FLOATprotected static intSIZEOF_INDEXprotected static intSIZEOF_INTprotected static intSIZEOF_SHORTSize of different types in bytesprotected PAppletsketchstatic intSRC_ALPHAstatic intSRC_ALPHA_SATURATEstatic intSRC_COLORstatic intSTATIC_DRAWstatic intSTENCIL_ATTACHMENTstatic intSTENCIL_BITSstatic intSTENCIL_BUFFER_BITstatic intSTENCIL_INDEXstatic intSTENCIL_INDEX1static intSTENCIL_INDEX4static intSTENCIL_INDEX8static intSTENCIL_TESTprotected ByteBufferstencilBufferprotected intstopButtonColorprotected intstopButtonHeightprotected intstopButtonWidthprotected intstopButtonXstatic intSTREAM_DRAWstatic intSTREAM_READprotected static floatSTROKE_DISPLACEMENTFactor used to displace the stroke vertices towards the camera in order to make sure the lines are always on top of the fill geometrystatic intSYNC_GPU_COMMANDS_COMPLETEprotected floattargetFpsstatic intTESS_EDGE_FLAGstatic intTESS_WINDING_NONZEROstatic intTESS_WINDING_ODDprotected inttex2DFragShaderprotected static String[]tex2DFragShaderSourceprotected inttex2DGeoVBOprotected inttex2DSamplerLocprotected inttex2DShaderContextprotected inttex2DShaderProgramprotected inttex2DTCoordLocprotected inttex2DVertLocprotected inttex2DVertShaderprotected float[]texCoordsprotected FloatBuffertexDataprotected inttexRectFragShaderprotected static String[]texRectFragShaderSourceprotected inttexRectGeoVBOprotected inttexRectSamplerLocprotected inttexRectShaderContextprotected inttexRectShaderProgramprotected inttexRectTCoordLocprotected inttexRectVertLocprotected inttexRectVertShaderstatic intTEXTURE_2Dstatic intTEXTURE_BINDING_2Dstatic intTEXTURE_BINDING_RECTANGLEstatic intTEXTURE_CUBE_MAPstatic intTEXTURE_CUBE_MAP_NEGATIVE_Xstatic intTEXTURE_CUBE_MAP_NEGATIVE_Ystatic intTEXTURE_CUBE_MAP_NEGATIVE_Zstatic intTEXTURE_CUBE_MAP_POSITIVE_Xstatic intTEXTURE_CUBE_MAP_POSITIVE_Ystatic intTEXTURE_CUBE_MAP_POSITIVE_Zstatic intTEXTURE_MAG_FILTERstatic intTEXTURE_MAX_ANISOTROPYstatic intTEXTURE_MIN_FILTERstatic intTEXTURE_RECTANGLEstatic intTEXTURE_WRAP_Rstatic intTEXTURE_WRAP_Sstatic intTEXTURE_WRAP_Tstatic intTEXTURE0static intTEXTURE1static intTEXTURE2static intTEXTURE3protected boolean[]texturingTargetsWhich texturing targets are enabledstatic StringTEXUNIT_ERRORprotected static String[]texVertShaderSourcestatic intTRIANGLE_FANstatic intTRIANGLE_STRIPstatic intTRIANGLESstatic intTRUEstatic intUNPACK_ALIGNMENTstatic intUNSIGNED_BYTEstatic intUNSIGNED_INTstatic intUNSIGNED_SHORTstatic intUNSIGNED_SHORT_4_4_4_4static intUNSIGNED_SHORT_5_5_5_1static intUNSIGNED_SHORT_5_6_5static StringUNSUPPORTED_GLPROF_ERRORprotected static booleanUSE_DIRECT_BUFFERSSwitches between the use of regular and direct buffers.protected booleanusingFrontTexFlags used to handle the creation of a separate front texturestatic intVALIDATE_STATUSstatic intVENDORstatic intVERSIONstatic intVERTEX_ATTRIB_ARRAY_BUFFER_BINDINGstatic intVERTEX_ATTRIB_ARRAY_ENABLEDstatic intVERTEX_ATTRIB_ARRAY_NORMALIZEDstatic intVERTEX_ATTRIB_ARRAY_POINTERstatic intVERTEX_ATTRIB_ARRAY_SIZEstatic intVERTEX_ATTRIB_ARRAY_STRIDEstatic intVERTEX_ATTRIB_ARRAY_TYPEstatic intVERTEX_SHADERprotected IntBufferviewBufferstatic intVIEWPORTstatic StringWIKIstatic intWRITE_ONLYstatic intZERO
-
Constructor Summary
Constructors Constructor Description PGL()PGL(PGraphicsOpenGL pg)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidactiveTexture(int texture)protected abstract voidactiveTextureImpl(int texture)protected static ByteBufferallocateByteBuffer(byte[] arr)protected static ByteBufferallocateByteBuffer(int size)protected static ByteBufferallocateDirectByteBuffer(int size)protected static FloatBufferallocateDirectFloatBuffer(int size)protected static IntBufferallocateDirectIntBuffer(int size)protected static ShortBufferallocateDirectShortBuffer(int size)protected static FloatBufferallocateFloatBuffer(float[] arr)protected static FloatBufferallocateFloatBuffer(int size)protected static IntBufferallocateIntBuffer(int size)protected static IntBufferallocateIntBuffer(int[] arr)protected static ShortBufferallocateShortBuffer(int size)protected static ShortBufferallocateShortBuffer(short[] arr)abstract voidattachShader(int program, int shader)protected voidbeginGL()protected voidbeginRender()abstract voidbindAttribLocation(int program, int index, String name)abstract voidbindBuffer(int target, int buffer)voidbindFramebuffer(int target, int framebuffer)protected abstract voidbindFramebufferImpl(int target, int framebuffer)protected voidbindFrontTexture()abstract voidbindRenderbuffer(int target, int renderbuffer)voidbindTexture(int target, int texture)protected abstract voidbindTextureImpl(int target, int texture)abstract voidblendColor(float red, float green, float blue, float alpha)abstract voidblendEquation(int mode)abstract voidblendEquationSeparate(int modeRGB, int modeAlpha)abstract voidblendFunc(int src, int dst)abstract voidblendFuncSeparate(int srcRGB, int dstRGB, int srcAlpha, int dstAlpha)abstract voidblitFramebuffer(int srcX0, int srcY0, int srcX1, int srcY1, int dstX0, int dstY0, int dstX1, int dstY1, int mask, int filter)abstract voidbufferData(int target, int size, Buffer data, int usage)abstract voidbufferSubData(int target, int offset, int size, Buffer data)protected abstract booleancanDraw()abstract intcheckFramebufferStatus(int target)abstract voidclear(int buf)protected voidclearBackground(float r, float g, float b, float a, boolean depth, boolean stencil)abstract voidclearColor(float r, float g, float b, float a)abstract voidclearDepth(float d)protected voidclearDepthStencil()abstract voidclearStencil(int s)abstract intclientWaitSync(long sync, int flags, long timeout)abstract voidcolorMask(boolean r, boolean g, boolean b, boolean a)protected booleancompiled(int shader)abstract voidcompileShader(int shader)abstract voidcompressedTexImage2D(int target, int level, int internalFormat, int width, int height, int border, int imageSize, Buffer data)abstract voidcompressedTexSubImage2D(int target, int level, int xOffset, int yOffset, int width, int height, int format, int imageSize, Buffer data)protected static booleancontainsVersionDirective(String[] shSrc)protected booleancontextIsCurrent(int other)abstract voidcopyTexImage2D(int target, int level, int internalFormat, int x, int y, int width, int height, int border)abstract voidcopyTexSubImage2D(int target, int level, int xOffset, int yOffset, int x, int y, int width, int height)protected voidcopyToTexture(int target, int format, int id, int x, int y, int w, int h, int[] buffer)protected voidcopyToTexture(int target, int format, int id, int x, int y, int w, int h, IntBuffer buffer)protected intcreateEmptyContext()protected abstract PGL.FontOutlinecreateFontOutline(char ch, Object font)abstract intcreateProgram()protected intcreateProgram(int vertexShader, int fragmentShader)abstract intcreateShader(int type)protected intcreateShader(int shaderType, String source)protected abstract PGL.TessellatorcreateTessellator(PGL.TessellatorCallback callback)abstract voidcullFace(int mode)abstract voiddeleteBuffers(int n, IntBuffer buffers)abstract voiddeleteFramebuffers(int n, IntBuffer framebuffers)abstract voiddeleteProgram(int program)abstract voiddeleteRenderbuffers(int n, IntBuffer renderbuffers)abstract voiddeleteShader(int shader)abstract voiddeleteSync(long sync)abstract voiddeleteTextures(int n, IntBuffer textures)abstract voiddepthFunc(int func)abstract voiddepthMask(boolean mask)abstract voiddepthRangef(float n, float f)protected voiddestroyFBOLayer()abstract voiddetachShader(int program, int shader)abstract voiddisable(int value)voiddisableFBOLayer()protected voiddisableTexturing(int target)abstract voiddisableVertexAttribArray(int index)voiddispose()voiddrawArrays(int mode, int first, int count)abstract voiddrawArraysImpl(int mode, int first, int count)abstract voiddrawBuffer(int buf)voiddrawElements(int mode, int count, int type, int offset)abstract voiddrawElementsImpl(int mode, int count, int type, int offset)voiddrawTexture(int target, int id, int width, int height, int X0, int Y0, int X1, int Y1)Not an approved function, this will change or be removed in the future.voiddrawTexture(int target, int id, int texW, int texH, int viewX, int viewY, int viewW, int viewH, int texX0, int texY0, int texX1, int texY1, int scrX0, int scrY0, int scrX1, int scrY1)Not an approved function, this will change or be removed in the future.voiddrawTexture(int target, int id, int texW, int texH, int viewX, int viewY, int viewW, int viewH, int viewF, int texX0, int texY0, int texX1, int texY1, int scrX0, int scrY0, int scrX1, int scrY1)protected voiddrawTexture2D(int id, int texW, int texH, int viewX, int viewY, int viewW, int viewH, int viewF, int texX0, int texY0, int texX1, int texY1, int scrX0, int scrY0, int scrX1, int scrY1)protected voiddrawTextureRect(int id, int texW, int texH, int viewX, int viewY, int viewW, int viewH, int viewF, int texX0, int texY0, int texX1, int texY1, int scrX0, int scrY0, int scrX1, int scrY1)abstract voidenable(int value)voidenableFBOLayer()protected voidenableTexturing(int target)abstract voidenableVertexAttribArray(int index)protected voidendGL()protected voidendRender(int windowColor)abstract StringerrorString(int err)abstract longfenceSync(int condition, int flags)protected static voidfillByteBuffer(ByteBuffer buf, int i0, int i1, byte val)protected static voidfillFloatBuffer(FloatBuffer buf, int i0, int i1, float val)protected static voidfillIntBuffer(IntBuffer buf, int i0, int i1, int val)protected static voidfillShortBuffer(ShortBuffer buf, int i0, int i1, short val)abstract voidfinish()abstract voidflush()abstract voidframebufferRenderbuffer(int target, int attachment, int rendbuferfTarget, int renderbuffer)abstract voidframebufferTexture2D(int target, int attachment, int texTarget, int texture, int level)abstract voidfrontFace(int dir)abstract voidgenBuffers(int n, IntBuffer buffers)abstract voidgenerateMipmap(int target)abstract voidgenFramebuffers(int n, IntBuffer framebuffers)abstract voidgenRenderbuffers(int n, IntBuffer renderbuffers)abstract voidgenTextures(int n, IntBuffer textures)abstract StringgetActiveAttrib(int program, int index, IntBuffer size, IntBuffer type)abstract StringgetActiveUniform(int program, int index, IntBuffer size, IntBuffer type)abstract voidgetAttachedShaders(int program, int maxCount, IntBuffer count, IntBuffer shaders)abstract intgetAttribLocation(int program, String name)abstract voidgetBooleanv(int value, IntBuffer data)abstract voidgetBufferParameteriv(int target, int value, IntBuffer data)protected static voidgetByteArray(ByteBuffer buf, byte[] arr)protected intgetColorValue(int scrX, int scrY)protected intgetCurrentContext()protected intgetDefaultDrawBuffer()protected intgetDefaultReadBuffer()protected abstract intgetDepthBits()protected booleangetDepthTest()protected floatgetDepthValue(int scrX, int scrY)protected booleangetDepthWriteMask()protected abstract ObjectgetDerivedFont(Object font, float size)protected intgetDrawFramebuffer()abstract intgetError()protected static voidgetFloatArray(FloatBuffer buf, float[] arr)abstract voidgetFloatv(int value, FloatBuffer data)protected abstract intgetFontAscent(Object font)protected abstract intgetFontDescent(Object font)abstract voidgetFramebufferAttachmentParameteriv(int target, int attachment, int pname, IntBuffer params)protected abstract voidgetGL(PGL pgl)protected abstract intgetGLSLVersion()protected abstract StringgetGLSLVersionSuffix()protected int[]getGLVersion()protected static voidgetIntArray(IntBuffer buf, int[] arr)abstract voidgetIntegerv(int value, IntBuffer data)protected intgetMaxTexUnits()abstract ObjectgetNative()protected abstract floatgetPixelScale()abstract StringgetProgramInfoLog(int program)abstract voidgetProgramiv(int program, int pname, IntBuffer params)protected intgetReadFramebuffer()abstract voidgetRenderbufferParameteriv(int target, int pname, IntBuffer params)abstract StringgetShaderInfoLog(int shader)abstract voidgetShaderiv(int shader, int pname, IntBuffer params)abstract voidgetShaderPrecisionFormat(int shaderType, int precisionType, IntBuffer range, IntBuffer precision)abstract StringgetShaderSource(int shader)protected static voidgetShortArray(ShortBuffer buf, short[] arr)protected abstract intgetStencilBits()protected bytegetStencilValue(int scrX, int scrY)abstract StringgetString(int name)abstract voidgetTexParameterfv(int target, int pname, FloatBuffer params)abstract voidgetTexParameteriv(int target, int pname, IntBuffer params)protected abstract intgetTextWidth(Object font, char[] buffer, int start, int stop)abstract voidgetUniformfv(int program, int location, FloatBuffer params)abstract voidgetUniformiv(int program, int location, IntBuffer params)abstract intgetUniformLocation(int program, String name)abstract voidgetVertexAttribfv(int index, int pname, FloatBuffer params)abstract voidgetVertexAttribiv(int index, int pname, IntBuffer params)abstract voidgetVertexAttribPointerv(int index, int pname, ByteBuffer data)protected booleanhasAnisoSamplingSupport()protected booleanhasAutoMipmapGenSupport()protected booleanhasDrawBuffer()protected booleanhasFboMultisampleSupport()protected booleanhasFBOs()protected booleanhasNpotTexSupport()protected booleanhasPackedDepthStencilSupport()protected booleanhasPBOs()protected booleanhasReadBuffer()protected booleanhasShaders()protected booleanhasSynchronization()abstract voidhint(int target, int hint)protected abstract voidinitFBOLayer()voidinitPresentMode(float x, float y, int stopColor)protected abstract voidinitSurface(int antialias)protected PGLinitTex2DShader()protected PGLinitTexRectShader()protected voidinitTexture(int target, int format, int width, int height)protected voidinitTexture(int target, int format, int width, int height, int initColor)booleaninsideStopButton(float x, float y)abstract voidisBuffer(int buffer)abstract booleanisEnabled(int value)protected booleanisES()protected booleanisFBOBacked()abstract booleanisFramebuffer(int framebuffer)protected booleanisMultisampled()protected static booleanisPowerOfTwo(int val)abstract booleanisProgram(int program)abstract booleanisRenderbuffer(int renderbuffer)abstract booleanisShader(int shader)abstract booleanisTexture(int texture)protected static intjavaToNativeARGB(int color)Converts input Java ARGB value to native OpenGL format (RGBA on big endian, BGRA on little endian).protected static voidjavaToNativeARGB(int[] pixels, int width, int height)Converts input array of Java ARGB values representing an image of width x height resolution to native OpenGL format (RGBA on big endian, BGRA on little endian).protected static intjavaToNativeRGB(int color)Converts input Java ARGB value to native OpenGL format (RGBA on big endian, BGRA on little endian), setting alpha component to opaque (255).protected static voidjavaToNativeRGB(int[] pixels, int width, int height)Converts input array of Java ARGB values representing an image of width x height resolution to native OpenGL format (RGBA on big endian, BGRA on little endian), while setting alpha component of all pixels to opaque (255).abstract voidlineWidth(float width)protected booleanlinked(int program)abstract voidlinkProgram(int program)protected String[]loadFragmentShader(String filename)protected String[]loadFragmentShader(String filename, int version, String versionSuffix)protected String[]loadFragmentShader(URL url)protected String[]loadFragmentShader(URL url, int version, String versionSuffix)protected String[]loadVertexShader(String filename)protected String[]loadVertexShader(String filename, int version, String versionSuffix)protected String[]loadVertexShader(URL url)protected String[]loadVertexShader(URL url, int version, String versionSuffix)abstract ByteBuffermapBuffer(int target, int access)abstract ByteBuffermapBufferRange(int target, int offset, int length, int access)protected intmaxSamples()protected static intnativeToJavaARGB(int color)Converts input native OpenGL value (RGBA on big endian, ABGR on little endian) to Java ARGB.protected static voidnativeToJavaARGB(int[] pixels, int width, int height)Converts input array of native OpenGL values (RGBA on big endian, ABGR on little endian) representing an image of width x height resolution to Java ARGB.protected static intnativeToJavaRGB(int color)Converts input native OpenGL value (RGBA on big endian, ABGR on little endian) to Java RGB, so that the alpha component of the result is set to opaque (255).protected static voidnativeToJavaRGB(int[] pixels, int width, int height)Converts input array of native OpenGL values (RGBA on big endian, ABGR on little endian) representing an image of width x height resolution to Java RGB, so that the alpha component of all pixels is set to opaque (255).protected static intnextPowerOfTwo(int val)abstract voidpixelStorei(int pname, int param)abstract voidpolygonOffset(float factor, float units)protected static String[]preprocessFragmentSource(String[] fragSrc0, int version, String versionSuffix)protected static String[]preprocessShaderSource(String[] src0, Pattern[] search, String[] replace, int offset)protected static String[]preprocessVertexSource(String[] vertSrc0, int version, String versionSuffix)booleanpresentMode()floatpresentX()floatpresentY()protected static voidputByteArray(ByteBuffer buf, byte[] arr)protected static voidputFloatArray(FloatBuffer buf, float[] arr)protected static voidputIntArray(IntBuffer buf, int[] arr)protected static voidputShortArray(ShortBuffer buf, short[] arr)protected static intqualityToSamples(int quality)abstract voidreadBuffer(int buf)voidreadPixels(int x, int y, int width, int height, int format, int type, long offset)voidreadPixels(int x, int y, int width, int height, int format, int type, Buffer buffer)protected abstract voidreadPixelsImpl(int x, int y, int width, int height, int format, int type, long offset)protected abstract voidreadPixelsImpl(int x, int y, int width, int height, int format, int type, Buffer buffer)protected abstract voidregisterListeners()protected abstract voidreinitSurface()abstract voidreleaseShaderCompiler()abstract voidrenderbufferStorage(int target, int internalFormat, int width, int height)abstract voidrenderbufferStorageMultisample(int target, int samples, int format, int width, int height)protected abstract voidrequestDraw()voidrequestFBOLayer()Deprecated.protected abstract voidrequestFocus()voidresetFBOLayer()protected voidrestoreFirstFrame()abstract voidsampleCoverage(float value, boolean invert)protected voidsaveFirstFrame()abstract voidscissor(int x, int y, int w, int h)protected abstract voidsetFrameRate(float fps)voidsetPrimary(boolean primary)voidsetThread(Thread thread)abstract voidshaderBinary(int count, IntBuffer shaders, int binaryFormat, Buffer binary, int length)abstract voidshaderSource(int shader, String source)static intsmoothToSamples(int smooth)abstract voidstencilFunc(int func, int ref, int mask)abstract voidstencilFuncSeparate(int face, int func, int ref, int mask)abstract voidstencilMask(int mask)abstract voidstencilMaskSeparate(int face, int mask)abstract voidstencilOp(int sfail, int dpfail, int dppass)abstract voidstencilOpSeparate(int face, int sfail, int dpfail, int dppass)protected abstract voidswapBuffers()protected voidsyncBackTexture()protected StringtessError(int err)abstract voidtexImage2D(int target, int level, int internalFormat, int width, int height, int border, int format, int type, Buffer data)abstract voidtexParameterf(int target, int pname, float param)abstract voidtexParameterfv(int target, int pname, FloatBuffer params)abstract voidtexParameteri(int target, int pname, int param)abstract voidtexParameteriv(int target, int pname, IntBuffer params)abstract voidtexSubImage2D(int target, int level, int xOffset, int yOffset, int width, int height, int format, int type, Buffer data)protected booleantextureIsBound(int target, int id)protected booleantexturingIsEnabled(int target)booleanthreadIsCurrent()protected voidunbindFrontTexture()abstract voiduniform1f(int location, float value)abstract voiduniform1fv(int location, int count, FloatBuffer v)abstract voiduniform1i(int location, int value)abstract voiduniform1iv(int location, int count, IntBuffer v)abstract voiduniform2f(int location, float value0, float value1)abstract voiduniform2fv(int location, int count, FloatBuffer v)abstract voiduniform2i(int location, int value0, int value1)abstract voiduniform2iv(int location, int count, IntBuffer v)abstract voiduniform3f(int location, float value0, float value1, float value2)abstract voiduniform3fv(int location, int count, FloatBuffer v)abstract voiduniform3i(int location, int value0, int value1, int value2)abstract voiduniform3iv(int location, int count, IntBuffer v)abstract voiduniform4f(int location, float value0, float value1, float value2, float value3)abstract voiduniform4fv(int location, int count, FloatBuffer v)abstract voiduniform4i(int location, int value0, int value1, int value2, int value3)abstract voiduniform4iv(int location, int count, IntBuffer v)abstract voiduniformMatrix2fv(int location, int count, boolean transpose, FloatBuffer mat)abstract voiduniformMatrix3fv(int location, int count, boolean transpose, FloatBuffer mat)abstract voiduniformMatrix4fv(int location, int count, boolean transpose, FloatBuffer mat)abstract voidunmapBuffer(int target)protected static ByteBufferupdateByteBuffer(ByteBuffer buf, byte[] arr, boolean wrap)protected static voidupdateByteBuffer(ByteBuffer buf, byte[] arr, int offset, int size)protected static FloatBufferupdateFloatBuffer(FloatBuffer buf, float[] arr, boolean wrap)protected static voidupdateFloatBuffer(FloatBuffer buf, float[] arr, int offset, int size)protected static IntBufferupdateIntBuffer(IntBuffer buf, int[] arr, boolean wrap)protected static voidupdateIntBuffer(IntBuffer buf, int[] arr, int offset, int size)protected static ShortBufferupdateShortBuffer(ShortBuffer buf, short[] arr, boolean wrap)protected static voidupdateShortBuffer(ShortBuffer buf, short[] arr, int offset, int size)abstract voiduseProgram(int program)protected intvalidateFramebuffer()abstract voidvalidateProgram(int program)abstract voidvertexAttrib1f(int index, float value)abstract voidvertexAttrib1fv(int index, FloatBuffer values)abstract voidvertexAttrib2f(int index, float value0, float value1)abstract voidvertexAttrib2fv(int index, FloatBuffer values)abstract voidvertexAttrib3f(int index, float value0, float value1, float value2)abstract voidvertexAttrib3fv(int index, FloatBuffer values)abstract voidvertexAttrib4f(int index, float value0, float value1, float value2, float value3)abstract voidvertexAttrib4fv(int index, FloatBuffer values)abstract voidvertexAttribPointer(int index, int size, int type, boolean normalized, int stride, int offset)abstract voidviewport(int x, int y, int w, int h)protected abstract voidviewportImpl(int x, int y, int w, int h)protected TexturewrapBackTexture(Texture texture)protected TexturewrapFrontTexture(Texture texture)
-
-
-
Field Detail
-
graphics
protected PGraphicsOpenGL graphics
The PGraphics and PApplet objects using this interface
-
sketch
protected PApplet sketch
-
glThread
protected Thread glThread
OpenGL thread
-
glContext
protected int glContext
ID of the GL context associated to the surface
-
primaryPGL
public boolean primaryPGL
true if this is the GL interface for a primary surface PGraphics
-
REQUESTED_DEPTH_BITS
public static int REQUESTED_DEPTH_BITS
-
REQUESTED_STENCIL_BITS
public static int REQUESTED_STENCIL_BITS
-
REQUESTED_ALPHA_BITS
public static int REQUESTED_ALPHA_BITS
-
USE_DIRECT_BUFFERS
protected static boolean USE_DIRECT_BUFFERS
Switches between the use of regular and direct buffers.
-
MIN_DIRECT_BUFFER_SIZE
protected static int MIN_DIRECT_BUFFER_SIZE
-
MIPMAPS_ENABLED
protected static boolean MIPMAPS_ENABLED
Enables/disables mipmap use.
-
DEFAULT_IN_VERTICES
protected static int DEFAULT_IN_VERTICES
Initial sizes for arrays of input and tessellated data.
-
DEFAULT_IN_EDGES
protected static int DEFAULT_IN_EDGES
-
DEFAULT_IN_TEXTURES
protected static int DEFAULT_IN_TEXTURES
-
DEFAULT_TESS_VERTICES
protected static int DEFAULT_TESS_VERTICES
-
DEFAULT_TESS_INDICES
protected static int DEFAULT_TESS_INDICES
-
MAX_LIGHTS
protected static int MAX_LIGHTS
Maximum lights by default is 8, the minimum defined by OpenGL.
-
MAX_VERTEX_INDEX
protected static int MAX_VERTEX_INDEX
Maximum index value of a tessellated vertex. GLES restricts the vertex indices to be of type unsigned short. Since Java only supports signed shorts as primitive type we have 2^15 = 32768 as the maximum number of vertices that can be referred to within a single VBO.
-
MAX_VERTEX_INDEX1
protected static int MAX_VERTEX_INDEX1
-
FLUSH_VERTEX_COUNT
protected static int FLUSH_VERTEX_COUNT
Count of tessellated fill, line or point vertices that will trigger a flush in the immediate mode. It doesn't necessarily be equal to MAX_VERTEX_INDEX1, since the number of vertices can be effectively much large since the renderer uses offsets to refer to vertices beyond the MAX_VERTEX_INDEX limit.
-
MIN_FONT_TEX_SIZE
protected static int MIN_FONT_TEX_SIZE
Minimum/maximum dimensions of a texture used to hold font data.
-
MAX_FONT_TEX_SIZE
protected static int MAX_FONT_TEX_SIZE
-
MIN_CAPS_JOINS_WEIGHT
protected static float MIN_CAPS_JOINS_WEIGHT
Minimum stroke weight needed to apply the full path stroking algorithm that properly generates caps and joins.
-
MAX_CAPS_JOINS_LENGTH
protected static int MAX_CAPS_JOINS_LENGTH
Maximum length of linear paths to be stroked with the full algorithm that generates accurate caps and joins.
-
MIN_ARRAYCOPY_SIZE
protected static int MIN_ARRAYCOPY_SIZE
Minimum array size to use arrayCopy method().
-
STROKE_DISPLACEMENT
protected static float STROKE_DISPLACEMENT
Factor used to displace the stroke vertices towards the camera in order to make sure the lines are always on top of the fill geometry
-
firstFrame
protected IntBuffer firstFrame
-
SINGLE_BUFFERED
protected static boolean SINGLE_BUFFERED
-
fboLayerEnabled
protected boolean fboLayerEnabled
-
fboLayerCreated
protected boolean fboLayerCreated
-
fboLayerEnabledReq
protected boolean fboLayerEnabledReq
-
fboLayerDisableReq
protected boolean fboLayerDisableReq
-
fbolayerResetReq
protected boolean fbolayerResetReq
-
reqNumSamples
public int reqNumSamples
-
numSamples
protected int numSamples
-
glColorFbo
protected IntBuffer glColorFbo
-
glColorTex
protected IntBuffer glColorTex
-
glDepthStencil
protected IntBuffer glDepthStencil
-
glDepth
protected IntBuffer glDepth
-
glStencil
protected IntBuffer glStencil
-
glMultiFbo
protected IntBuffer glMultiFbo
-
glMultiColor
protected IntBuffer glMultiColor
-
glMultiDepthStencil
protected IntBuffer glMultiDepthStencil
-
glMultiDepth
protected IntBuffer glMultiDepth
-
glMultiStencil
protected IntBuffer glMultiStencil
-
fboWidth
protected int fboWidth
-
fboHeight
protected int fboHeight
-
backTex
protected int backTex
-
frontTex
protected int frontTex
-
usingFrontTex
protected boolean usingFrontTex
Flags used to handle the creation of a separate front texture
-
needSepFrontTex
protected boolean needSepFrontTex
-
loadedTex2DShader
protected boolean loadedTex2DShader
-
tex2DShaderProgram
protected int tex2DShaderProgram
-
tex2DVertShader
protected int tex2DVertShader
-
tex2DFragShader
protected int tex2DFragShader
-
tex2DShaderContext
protected int tex2DShaderContext
-
tex2DVertLoc
protected int tex2DVertLoc
-
tex2DTCoordLoc
protected int tex2DTCoordLoc
-
tex2DSamplerLoc
protected int tex2DSamplerLoc
-
tex2DGeoVBO
protected int tex2DGeoVBO
-
loadedTexRectShader
protected boolean loadedTexRectShader
-
texRectShaderProgram
protected int texRectShaderProgram
-
texRectVertShader
protected int texRectVertShader
-
texRectFragShader
protected int texRectFragShader
-
texRectShaderContext
protected int texRectShaderContext
-
texRectVertLoc
protected int texRectVertLoc
-
texRectTCoordLoc
protected int texRectTCoordLoc
-
texRectSamplerLoc
protected int texRectSamplerLoc
-
texRectGeoVBO
protected int texRectGeoVBO
-
texCoords
protected float[] texCoords
-
texData
protected FloatBuffer texData
-
SHADER_PREPROCESSOR_DIRECTIVE
protected static final String SHADER_PREPROCESSOR_DIRECTIVE
- See Also:
- Constant Field Values
-
texVertShaderSource
protected static String[] texVertShaderSource
-
tex2DFragShaderSource
protected static String[] tex2DFragShaderSource
-
texRectFragShaderSource
protected static String[] texRectFragShaderSource
-
texturingTargets
protected boolean[] texturingTargets
Which texturing targets are enabled
-
maxTexUnits
protected int maxTexUnits
Used to keep track of which textures are bound to each target
-
activeTexUnit
protected int activeTexUnit
-
boundTextures
protected int[][] boundTextures
-
targetFps
protected float targetFps
-
currentFps
protected float currentFps
-
setFps
protected boolean setFps
-
byteBuffer
protected ByteBuffer byteBuffer
-
intBuffer
protected IntBuffer intBuffer
-
viewBuffer
protected IntBuffer viewBuffer
-
colorBuffer
protected IntBuffer colorBuffer
-
depthBuffer
protected FloatBuffer depthBuffer
-
stencilBuffer
protected ByteBuffer stencilBuffer
-
geomCount
protected int geomCount
Used to register amount of geometry rendered in each frame.
-
pgeomCount
protected int pgeomCount
-
clearColor
protected boolean clearColor
Used to register calls to background.
-
pclearColor
protected boolean pclearColor
-
clearDepth
protected boolean clearDepth
-
pclearDepth
protected boolean pclearDepth
-
clearStencil
protected boolean clearStencil
-
pclearStencil
protected boolean pclearStencil
-
WIKI
public static final String WIKI
- See Also:
- Constant Field Values
-
FRAMEBUFFER_ERROR
public static final String FRAMEBUFFER_ERROR
- See Also:
- Constant Field Values
-
MISSING_FBO_ERROR
public static final String MISSING_FBO_ERROR
- See Also:
- Constant Field Values
-
MISSING_GLSL_ERROR
public static final String MISSING_GLSL_ERROR
- See Also:
- Constant Field Values
-
MISSING_GLFUNC_ERROR
public static final String MISSING_GLFUNC_ERROR
- See Also:
- Constant Field Values
-
UNSUPPORTED_GLPROF_ERROR
public static final String UNSUPPORTED_GLPROF_ERROR
- See Also:
- Constant Field Values
-
TEXUNIT_ERROR
public static final String TEXUNIT_ERROR
- See Also:
- Constant Field Values
-
NONPRIMARY_ERROR
public static final String NONPRIMARY_ERROR
- See Also:
- Constant Field Values
-
DEPTH_READING_NOT_ENABLED_ERROR
protected static final String DEPTH_READING_NOT_ENABLED_ERROR
- See Also:
- Constant Field Values
-
SIZEOF_SHORT
protected static int SIZEOF_SHORT
Size of different types in bytes
-
SIZEOF_INT
protected static int SIZEOF_INT
-
SIZEOF_FLOAT
protected static int SIZEOF_FLOAT
-
SIZEOF_BYTE
protected static int SIZEOF_BYTE
-
SIZEOF_INDEX
protected static int SIZEOF_INDEX
-
INDEX_TYPE
protected static int INDEX_TYPE
-
FLOAT_EPS
protected static float FLOAT_EPS
Machine Epsilon for float precision.
-
BIG_ENDIAN
protected static boolean BIG_ENDIAN
Set to true if the host system is big endian (PowerPC, MIPS, SPARC), false if little endian (x86 Intel for Mac or PC).
-
presentMode
protected boolean presentMode
-
showStopButton
protected boolean showStopButton
-
presentX
public float presentX
-
presentY
public float presentY
-
closeButtonTex
protected IntBuffer closeButtonTex
-
stopButtonColor
protected int stopButtonColor
-
stopButtonWidth
protected int stopButtonWidth
-
stopButtonHeight
protected int stopButtonHeight
-
stopButtonX
protected int stopButtonX
-
closeButtonY
protected int closeButtonY
-
closeButtonPix
protected static int[] closeButtonPix
-
GLSL_ID_REGEX
protected static final String GLSL_ID_REGEX
- See Also:
- Constant Field Values
-
GLSL_FN_REGEX
protected static final String GLSL_FN_REGEX
- See Also:
- Constant Field Values
-
SHAPE_TEXT_SUPPORTED
protected static boolean SHAPE_TEXT_SUPPORTED
-
SEG_MOVETO
protected static int SEG_MOVETO
-
SEG_LINETO
protected static int SEG_LINETO
-
SEG_QUADTO
protected static int SEG_QUADTO
-
SEG_CUBICTO
protected static int SEG_CUBICTO
-
SEG_CLOSE
protected static int SEG_CLOSE
-
FALSE
public static int FALSE
-
TRUE
public static int TRUE
-
INT
public static int INT
-
BYTE
public static int BYTE
-
SHORT
public static int SHORT
-
FLOAT
public static int FLOAT
-
BOOL
public static int BOOL
-
UNSIGNED_INT
public static int UNSIGNED_INT
-
UNSIGNED_BYTE
public static int UNSIGNED_BYTE
-
UNSIGNED_SHORT
public static int UNSIGNED_SHORT
-
RGB
public static int RGB
-
RGBA
public static int RGBA
-
ALPHA
public static int ALPHA
-
LUMINANCE
public static int LUMINANCE
-
LUMINANCE_ALPHA
public static int LUMINANCE_ALPHA
-
UNSIGNED_SHORT_5_6_5
public static int UNSIGNED_SHORT_5_6_5
-
UNSIGNED_SHORT_4_4_4_4
public static int UNSIGNED_SHORT_4_4_4_4
-
UNSIGNED_SHORT_5_5_5_1
public static int UNSIGNED_SHORT_5_5_5_1
-
RGBA4
public static int RGBA4
-
RGB5_A1
public static int RGB5_A1
-
RGB565
public static int RGB565
-
RGB8
public static int RGB8
-
RGBA8
public static int RGBA8
-
ALPHA8
public static int ALPHA8
-
READ_ONLY
public static int READ_ONLY
-
WRITE_ONLY
public static int WRITE_ONLY
-
READ_WRITE
public static int READ_WRITE
-
TESS_WINDING_NONZERO
public static int TESS_WINDING_NONZERO
-
TESS_WINDING_ODD
public static int TESS_WINDING_ODD
-
TESS_EDGE_FLAG
public static int TESS_EDGE_FLAG
-
GENERATE_MIPMAP_HINT
public static int GENERATE_MIPMAP_HINT
-
FASTEST
public static int FASTEST
-
NICEST
public static int NICEST
-
DONT_CARE
public static int DONT_CARE
-
VENDOR
public static int VENDOR
-
RENDERER
public static int RENDERER
-
VERSION
public static int VERSION
-
EXTENSIONS
public static int EXTENSIONS
-
SHADING_LANGUAGE_VERSION
public static int SHADING_LANGUAGE_VERSION
-
MAX_SAMPLES
public static int MAX_SAMPLES
-
SAMPLES
public static int SAMPLES
-
ALIASED_LINE_WIDTH_RANGE
public static int ALIASED_LINE_WIDTH_RANGE
-
ALIASED_POINT_SIZE_RANGE
public static int ALIASED_POINT_SIZE_RANGE
-
DEPTH_BITS
public static int DEPTH_BITS
-
STENCIL_BITS
public static int STENCIL_BITS
-
CCW
public static int CCW
-
CW
public static int CW
-
VIEWPORT
public static int VIEWPORT
-
ARRAY_BUFFER
public static int ARRAY_BUFFER
-
ELEMENT_ARRAY_BUFFER
public static int ELEMENT_ARRAY_BUFFER
-
PIXEL_PACK_BUFFER
public static int PIXEL_PACK_BUFFER
-
MAX_VERTEX_ATTRIBS
public static int MAX_VERTEX_ATTRIBS
-
STATIC_DRAW
public static int STATIC_DRAW
-
DYNAMIC_DRAW
public static int DYNAMIC_DRAW
-
STREAM_DRAW
public static int STREAM_DRAW
-
STREAM_READ
public static int STREAM_READ
-
BUFFER_SIZE
public static int BUFFER_SIZE
-
BUFFER_USAGE
public static int BUFFER_USAGE
-
POINTS
public static int POINTS
-
LINE_STRIP
public static int LINE_STRIP
-
LINE_LOOP
public static int LINE_LOOP
-
LINES
public static int LINES
-
TRIANGLE_FAN
public static int TRIANGLE_FAN
-
TRIANGLE_STRIP
public static int TRIANGLE_STRIP
-
TRIANGLES
public static int TRIANGLES
-
CULL_FACE
public static int CULL_FACE
-
FRONT
public static int FRONT
-
BACK
public static int BACK
-
FRONT_AND_BACK
public static int FRONT_AND_BACK
-
POLYGON_OFFSET_FILL
public static int POLYGON_OFFSET_FILL
-
UNPACK_ALIGNMENT
public static int UNPACK_ALIGNMENT
-
PACK_ALIGNMENT
public static int PACK_ALIGNMENT
-
TEXTURE_2D
public static int TEXTURE_2D
-
TEXTURE_RECTANGLE
public static int TEXTURE_RECTANGLE
-
TEXTURE_BINDING_2D
public static int TEXTURE_BINDING_2D
-
TEXTURE_BINDING_RECTANGLE
public static int TEXTURE_BINDING_RECTANGLE
-
MAX_TEXTURE_SIZE
public static int MAX_TEXTURE_SIZE
-
TEXTURE_MAX_ANISOTROPY
public static int TEXTURE_MAX_ANISOTROPY
-
MAX_TEXTURE_MAX_ANISOTROPY
public static int MAX_TEXTURE_MAX_ANISOTROPY
-
MAX_VERTEX_TEXTURE_IMAGE_UNITS
public static int MAX_VERTEX_TEXTURE_IMAGE_UNITS
-
MAX_TEXTURE_IMAGE_UNITS
public static int MAX_TEXTURE_IMAGE_UNITS
-
MAX_COMBINED_TEXTURE_IMAGE_UNITS
public static int MAX_COMBINED_TEXTURE_IMAGE_UNITS
-
NUM_COMPRESSED_TEXTURE_FORMATS
public static int NUM_COMPRESSED_TEXTURE_FORMATS
-
COMPRESSED_TEXTURE_FORMATS
public static int COMPRESSED_TEXTURE_FORMATS
-
NEAREST
public static int NEAREST
-
LINEAR
public static int LINEAR
-
LINEAR_MIPMAP_NEAREST
public static int LINEAR_MIPMAP_NEAREST
-
LINEAR_MIPMAP_LINEAR
public static int LINEAR_MIPMAP_LINEAR
-
CLAMP_TO_EDGE
public static int CLAMP_TO_EDGE
-
REPEAT
public static int REPEAT
-
TEXTURE0
public static int TEXTURE0
-
TEXTURE1
public static int TEXTURE1
-
TEXTURE2
public static int TEXTURE2
-
TEXTURE3
public static int TEXTURE3
-
TEXTURE_MIN_FILTER
public static int TEXTURE_MIN_FILTER
-
TEXTURE_MAG_FILTER
public static int TEXTURE_MAG_FILTER
-
TEXTURE_WRAP_S
public static int TEXTURE_WRAP_S
-
TEXTURE_WRAP_T
public static int TEXTURE_WRAP_T
-
TEXTURE_WRAP_R
public static int TEXTURE_WRAP_R
-
TEXTURE_CUBE_MAP
public static int TEXTURE_CUBE_MAP
-
TEXTURE_CUBE_MAP_POSITIVE_X
public static int TEXTURE_CUBE_MAP_POSITIVE_X
-
TEXTURE_CUBE_MAP_POSITIVE_Y
public static int TEXTURE_CUBE_MAP_POSITIVE_Y
-
TEXTURE_CUBE_MAP_POSITIVE_Z
public static int TEXTURE_CUBE_MAP_POSITIVE_Z
-
TEXTURE_CUBE_MAP_NEGATIVE_X
public static int TEXTURE_CUBE_MAP_NEGATIVE_X
-
TEXTURE_CUBE_MAP_NEGATIVE_Y
public static int TEXTURE_CUBE_MAP_NEGATIVE_Y
-
TEXTURE_CUBE_MAP_NEGATIVE_Z
public static int TEXTURE_CUBE_MAP_NEGATIVE_Z
-
VERTEX_SHADER
public static int VERTEX_SHADER
-
FRAGMENT_SHADER
public static int FRAGMENT_SHADER
-
INFO_LOG_LENGTH
public static int INFO_LOG_LENGTH
-
SHADER_SOURCE_LENGTH
public static int SHADER_SOURCE_LENGTH
-
COMPILE_STATUS
public static int COMPILE_STATUS
-
LINK_STATUS
public static int LINK_STATUS
-
VALIDATE_STATUS
public static int VALIDATE_STATUS
-
SHADER_TYPE
public static int SHADER_TYPE
-
DELETE_STATUS
public static int DELETE_STATUS
-
FLOAT_VEC2
public static int FLOAT_VEC2
-
FLOAT_VEC3
public static int FLOAT_VEC3
-
FLOAT_VEC4
public static int FLOAT_VEC4
-
FLOAT_MAT2
public static int FLOAT_MAT2
-
FLOAT_MAT3
public static int FLOAT_MAT3
-
FLOAT_MAT4
public static int FLOAT_MAT4
-
INT_VEC2
public static int INT_VEC2
-
INT_VEC3
public static int INT_VEC3
-
INT_VEC4
public static int INT_VEC4
-
BOOL_VEC2
public static int BOOL_VEC2
-
BOOL_VEC3
public static int BOOL_VEC3
-
BOOL_VEC4
public static int BOOL_VEC4
-
SAMPLER_2D
public static int SAMPLER_2D
-
SAMPLER_CUBE
public static int SAMPLER_CUBE
-
LOW_FLOAT
public static int LOW_FLOAT
-
MEDIUM_FLOAT
public static int MEDIUM_FLOAT
-
HIGH_FLOAT
public static int HIGH_FLOAT
-
LOW_INT
public static int LOW_INT
-
MEDIUM_INT
public static int MEDIUM_INT
-
HIGH_INT
public static int HIGH_INT
-
CURRENT_VERTEX_ATTRIB
public static int CURRENT_VERTEX_ATTRIB
-
VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
public static int VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
-
VERTEX_ATTRIB_ARRAY_ENABLED
public static int VERTEX_ATTRIB_ARRAY_ENABLED
-
VERTEX_ATTRIB_ARRAY_SIZE
public static int VERTEX_ATTRIB_ARRAY_SIZE
-
VERTEX_ATTRIB_ARRAY_STRIDE
public static int VERTEX_ATTRIB_ARRAY_STRIDE
-
VERTEX_ATTRIB_ARRAY_TYPE
public static int VERTEX_ATTRIB_ARRAY_TYPE
-
VERTEX_ATTRIB_ARRAY_NORMALIZED
public static int VERTEX_ATTRIB_ARRAY_NORMALIZED
-
VERTEX_ATTRIB_ARRAY_POINTER
public static int VERTEX_ATTRIB_ARRAY_POINTER
-
BLEND
public static int BLEND
-
ONE
public static int ONE
-
ZERO
public static int ZERO
-
SRC_ALPHA
public static int SRC_ALPHA
-
DST_ALPHA
public static int DST_ALPHA
-
ONE_MINUS_SRC_ALPHA
public static int ONE_MINUS_SRC_ALPHA
-
ONE_MINUS_DST_COLOR
public static int ONE_MINUS_DST_COLOR
-
ONE_MINUS_SRC_COLOR
public static int ONE_MINUS_SRC_COLOR
-
DST_COLOR
public static int DST_COLOR
-
SRC_COLOR
public static int SRC_COLOR
-
SAMPLE_ALPHA_TO_COVERAGE
public static int SAMPLE_ALPHA_TO_COVERAGE
-
SAMPLE_COVERAGE
public static int SAMPLE_COVERAGE
-
KEEP
public static int KEEP
-
REPLACE
public static int REPLACE
-
INCR
public static int INCR
-
DECR
public static int DECR
-
INVERT
public static int INVERT
-
INCR_WRAP
public static int INCR_WRAP
-
DECR_WRAP
public static int DECR_WRAP
-
NEVER
public static int NEVER
-
ALWAYS
public static int ALWAYS
-
EQUAL
public static int EQUAL
-
LESS
public static int LESS
-
LEQUAL
public static int LEQUAL
-
GREATER
public static int GREATER
-
GEQUAL
public static int GEQUAL
-
NOTEQUAL
public static int NOTEQUAL
-
FUNC_ADD
public static int FUNC_ADD
-
FUNC_MIN
public static int FUNC_MIN
-
FUNC_MAX
public static int FUNC_MAX
-
FUNC_REVERSE_SUBTRACT
public static int FUNC_REVERSE_SUBTRACT
-
FUNC_SUBTRACT
public static int FUNC_SUBTRACT
-
DITHER
public static int DITHER
-
CONSTANT_COLOR
public static int CONSTANT_COLOR
-
CONSTANT_ALPHA
public static int CONSTANT_ALPHA
-
ONE_MINUS_CONSTANT_COLOR
public static int ONE_MINUS_CONSTANT_COLOR
-
ONE_MINUS_CONSTANT_ALPHA
public static int ONE_MINUS_CONSTANT_ALPHA
-
SRC_ALPHA_SATURATE
public static int SRC_ALPHA_SATURATE
-
SCISSOR_TEST
public static int SCISSOR_TEST
-
STENCIL_TEST
public static int STENCIL_TEST
-
DEPTH_TEST
public static int DEPTH_TEST
-
DEPTH_WRITEMASK
public static int DEPTH_WRITEMASK
-
COLOR_BUFFER_BIT
public static int COLOR_BUFFER_BIT
-
DEPTH_BUFFER_BIT
public static int DEPTH_BUFFER_BIT
-
STENCIL_BUFFER_BIT
public static int STENCIL_BUFFER_BIT
-
FRAMEBUFFER
public static int FRAMEBUFFER
-
COLOR_ATTACHMENT0
public static int COLOR_ATTACHMENT0
-
COLOR_ATTACHMENT1
public static int COLOR_ATTACHMENT1
-
COLOR_ATTACHMENT2
public static int COLOR_ATTACHMENT2
-
COLOR_ATTACHMENT3
public static int COLOR_ATTACHMENT3
-
RENDERBUFFER
public static int RENDERBUFFER
-
DEPTH_ATTACHMENT
public static int DEPTH_ATTACHMENT
-
STENCIL_ATTACHMENT
public static int STENCIL_ATTACHMENT
-
READ_FRAMEBUFFER
public static int READ_FRAMEBUFFER
-
DRAW_FRAMEBUFFER
public static int DRAW_FRAMEBUFFER
-
DEPTH24_STENCIL8
public static int DEPTH24_STENCIL8
-
DEPTH_COMPONENT
public static int DEPTH_COMPONENT
-
DEPTH_COMPONENT16
public static int DEPTH_COMPONENT16
-
DEPTH_COMPONENT24
public static int DEPTH_COMPONENT24
-
DEPTH_COMPONENT32
public static int DEPTH_COMPONENT32
-
STENCIL_INDEX
public static int STENCIL_INDEX
-
STENCIL_INDEX1
public static int STENCIL_INDEX1
-
STENCIL_INDEX4
public static int STENCIL_INDEX4
-
STENCIL_INDEX8
public static int STENCIL_INDEX8
-
DEPTH_STENCIL
public static int DEPTH_STENCIL
-
FRAMEBUFFER_COMPLETE
public static int FRAMEBUFFER_COMPLETE
-
FRAMEBUFFER_UNDEFINED
public static int FRAMEBUFFER_UNDEFINED
-
FRAMEBUFFER_INCOMPLETE_ATTACHMENT
public static int FRAMEBUFFER_INCOMPLETE_ATTACHMENT
-
FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT
public static int FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT
-
FRAMEBUFFER_INCOMPLETE_DIMENSIONS
public static int FRAMEBUFFER_INCOMPLETE_DIMENSIONS
-
FRAMEBUFFER_INCOMPLETE_FORMATS
public static int FRAMEBUFFER_INCOMPLETE_FORMATS
-
FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER
public static int FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER
-
FRAMEBUFFER_INCOMPLETE_READ_BUFFER
public static int FRAMEBUFFER_INCOMPLETE_READ_BUFFER
-
FRAMEBUFFER_UNSUPPORTED
public static int FRAMEBUFFER_UNSUPPORTED
-
FRAMEBUFFER_INCOMPLETE_MULTISAMPLE
public static int FRAMEBUFFER_INCOMPLETE_MULTISAMPLE
-
FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS
public static int FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS
-
FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE
public static int FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE
-
FRAMEBUFFER_ATTACHMENT_OBJECT_NAME
public static int FRAMEBUFFER_ATTACHMENT_OBJECT_NAME
-
FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL
public static int FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL
-
FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE
public static int FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE
-
RENDERBUFFER_WIDTH
public static int RENDERBUFFER_WIDTH
-
RENDERBUFFER_HEIGHT
public static int RENDERBUFFER_HEIGHT
-
RENDERBUFFER_RED_SIZE
public static int RENDERBUFFER_RED_SIZE
-
RENDERBUFFER_GREEN_SIZE
public static int RENDERBUFFER_GREEN_SIZE
-
RENDERBUFFER_BLUE_SIZE
public static int RENDERBUFFER_BLUE_SIZE
-
RENDERBUFFER_ALPHA_SIZE
public static int RENDERBUFFER_ALPHA_SIZE
-
RENDERBUFFER_DEPTH_SIZE
public static int RENDERBUFFER_DEPTH_SIZE
-
RENDERBUFFER_STENCIL_SIZE
public static int RENDERBUFFER_STENCIL_SIZE
-
RENDERBUFFER_INTERNAL_FORMAT
public static int RENDERBUFFER_INTERNAL_FORMAT
-
MULTISAMPLE
public static int MULTISAMPLE
-
LINE_SMOOTH
public static int LINE_SMOOTH
-
POLYGON_SMOOTH
public static int POLYGON_SMOOTH
-
SYNC_GPU_COMMANDS_COMPLETE
public static int SYNC_GPU_COMMANDS_COMPLETE
-
ALREADY_SIGNALED
public static int ALREADY_SIGNALED
-
CONDITION_SATISFIED
public static int CONDITION_SATISFIED
-
-
Constructor Detail
-
PGL
public PGL()
-
PGL
public PGL(PGraphicsOpenGL pg)
-
-
Method Detail
-
dispose
public void dispose()
-
setPrimary
public void setPrimary(boolean primary)
-
smoothToSamples
public static int smoothToSamples(int smooth)
-
getNative
public abstract Object getNative()
-
setFrameRate
protected abstract void setFrameRate(float fps)
-
initSurface
protected abstract void initSurface(int antialias)
-
reinitSurface
protected abstract void reinitSurface()
-
registerListeners
protected abstract void registerListeners()
-
getReadFramebuffer
protected int getReadFramebuffer()
-
getDrawFramebuffer
protected int getDrawFramebuffer()
-
getDefaultDrawBuffer
protected int getDefaultDrawBuffer()
-
getDefaultReadBuffer
protected int getDefaultReadBuffer()
-
isFBOBacked
protected boolean isFBOBacked()
-
requestFBOLayer
@Deprecated public void requestFBOLayer()
Deprecated.
-
enableFBOLayer
public void enableFBOLayer()
-
disableFBOLayer
public void disableFBOLayer()
-
resetFBOLayer
public void resetFBOLayer()
-
isMultisampled
protected boolean isMultisampled()
-
getDepthBits
protected abstract int getDepthBits()
-
getStencilBits
protected abstract int getStencilBits()
-
getDepthTest
protected boolean getDepthTest()
-
getDepthWriteMask
protected boolean getDepthWriteMask()
-
bindFrontTexture
protected void bindFrontTexture()
-
unbindFrontTexture
protected void unbindFrontTexture()
-
syncBackTexture
protected void syncBackTexture()
-
getPixelScale
protected abstract float getPixelScale()
-
initPresentMode
public void initPresentMode(float x, float y, int stopColor)
-
presentMode
public boolean presentMode()
-
presentX
public float presentX()
-
presentY
public float presentY()
-
insideStopButton
public boolean insideStopButton(float x, float y)
-
clearDepthStencil
protected void clearDepthStencil()
-
clearBackground
protected void clearBackground(float r, float g, float b, float a, boolean depth, boolean stencil)
-
beginRender
protected void beginRender()
-
endRender
protected void endRender(int windowColor)
-
getGL
protected abstract void getGL(PGL pgl)
-
canDraw
protected abstract boolean canDraw()
-
requestFocus
protected abstract void requestFocus()
-
requestDraw
protected abstract void requestDraw()
-
swapBuffers
protected abstract void swapBuffers()
-
threadIsCurrent
public boolean threadIsCurrent()
-
setThread
public void setThread(Thread thread)
-
beginGL
protected void beginGL()
-
endGL
protected void endGL()
-
initFBOLayer
protected abstract void initFBOLayer()
-
saveFirstFrame
protected void saveFirstFrame()
-
restoreFirstFrame
protected void restoreFirstFrame()
-
destroyFBOLayer
protected void destroyFBOLayer()
-
createEmptyContext
protected int createEmptyContext()
-
getCurrentContext
protected int getCurrentContext()
-
contextIsCurrent
protected boolean contextIsCurrent(int other)
-
enableTexturing
protected void enableTexturing(int target)
-
disableTexturing
protected void disableTexturing(int target)
-
texturingIsEnabled
protected boolean texturingIsEnabled(int target)
-
textureIsBound
protected boolean textureIsBound(int target, int id)
-
initTexture
protected void initTexture(int target, int format, int width, int height)
-
initTexture
protected void initTexture(int target, int format, int width, int height, int initColor)
-
copyToTexture
protected void copyToTexture(int target, int format, int id, int x, int y, int w, int h, int[] buffer)
-
copyToTexture
protected void copyToTexture(int target, int format, int id, int x, int y, int w, int h, IntBuffer buffer)
-
drawTexture
public void drawTexture(int target, int id, int width, int height, int X0, int Y0, int X1, int Y1)Not an approved function, this will change or be removed in the future.
-
drawTexture
public void drawTexture(int target, int id, int texW, int texH, int viewX, int viewY, int viewW, int viewH, int texX0, int texY0, int texX1, int texY1, int scrX0, int scrY0, int scrX1, int scrY1)Not an approved function, this will change or be removed in the future.
-
drawTexture
public void drawTexture(int target, int id, int texW, int texH, int viewX, int viewY, int viewW, int viewH, int viewF, int texX0, int texY0, int texX1, int texY1, int scrX0, int scrY0, int scrX1, int scrY1)
-
initTex2DShader
protected PGL initTex2DShader()
-
drawTexture2D
protected void drawTexture2D(int id, int texW, int texH, int viewX, int viewY, int viewW, int viewH, int viewF, int texX0, int texY0, int texX1, int texY1, int scrX0, int scrY0, int scrX1, int scrY1)
-
initTexRectShader
protected PGL initTexRectShader()
-
drawTextureRect
protected void drawTextureRect(int id, int texW, int texH, int viewX, int viewY, int viewW, int viewH, int viewF, int texX0, int texY0, int texX1, int texY1, int scrX0, int scrY0, int scrX1, int scrY1)
-
getColorValue
protected int getColorValue(int scrX, int scrY)
-
getDepthValue
protected float getDepthValue(int scrX, int scrY)
-
getStencilValue
protected byte getStencilValue(int scrX, int scrY)
-
isPowerOfTwo
protected static boolean isPowerOfTwo(int val)
-
nextPowerOfTwo
protected static int nextPowerOfTwo(int val)
-
nativeToJavaARGB
protected static int nativeToJavaARGB(int color)
Converts input native OpenGL value (RGBA on big endian, ABGR on little endian) to Java ARGB.
-
nativeToJavaARGB
protected static void nativeToJavaARGB(int[] pixels, int width, int height)Converts input array of native OpenGL values (RGBA on big endian, ABGR on little endian) representing an image of width x height resolution to Java ARGB. It also rearranges the elements in the array so that the image is flipped vertically.
-
nativeToJavaRGB
protected static int nativeToJavaRGB(int color)
Converts input native OpenGL value (RGBA on big endian, ABGR on little endian) to Java RGB, so that the alpha component of the result is set to opaque (255).
-
nativeToJavaRGB
protected static void nativeToJavaRGB(int[] pixels, int width, int height)Converts input array of native OpenGL values (RGBA on big endian, ABGR on little endian) representing an image of width x height resolution to Java RGB, so that the alpha component of all pixels is set to opaque (255). It also rearranges the elements in the array so that the image is flipped vertically.
-
javaToNativeARGB
protected static int javaToNativeARGB(int color)
Converts input Java ARGB value to native OpenGL format (RGBA on big endian, BGRA on little endian).
-
javaToNativeARGB
protected static void javaToNativeARGB(int[] pixels, int width, int height)Converts input array of Java ARGB values representing an image of width x height resolution to native OpenGL format (RGBA on big endian, BGRA on little endian). It also rearranges the elements in the array so that the image is flipped vertically.
-
javaToNativeRGB
protected static int javaToNativeRGB(int color)
Converts input Java ARGB value to native OpenGL format (RGBA on big endian, BGRA on little endian), setting alpha component to opaque (255).
-
javaToNativeRGB
protected static void javaToNativeRGB(int[] pixels, int width, int height)Converts input array of Java ARGB values representing an image of width x height resolution to native OpenGL format (RGBA on big endian, BGRA on little endian), while setting alpha component of all pixels to opaque (255). It also rearranges the elements in the array so that the image is flipped vertically.
-
qualityToSamples
protected static int qualityToSamples(int quality)
-
getGLSLVersion
protected abstract int getGLSLVersion()
-
getGLSLVersionSuffix
protected abstract String getGLSLVersionSuffix()
-
loadVertexShader
protected String[] loadVertexShader(String filename, int version, String versionSuffix)
-
loadFragmentShader
protected String[] loadFragmentShader(String filename, int version, String versionSuffix)
-
loadFragmentShader
protected String[] loadFragmentShader(URL url, int version, String versionSuffix)
-
preprocessFragmentSource
protected static String[] preprocessFragmentSource(String[] fragSrc0, int version, String versionSuffix)
-
preprocessVertexSource
protected static String[] preprocessVertexSource(String[] vertSrc0, int version, String versionSuffix)
-
preprocessShaderSource
protected static String[] preprocessShaderSource(String[] src0, Pattern[] search, String[] replace, int offset)
-
containsVersionDirective
protected static boolean containsVersionDirective(String[] shSrc)
-
createShader
protected int createShader(int shaderType, String source)
-
createProgram
protected int createProgram(int vertexShader, int fragmentShader)
-
compiled
protected boolean compiled(int shader)
-
linked
protected boolean linked(int program)
-
validateFramebuffer
protected int validateFramebuffer()
-
isES
protected boolean isES()
-
getGLVersion
protected int[] getGLVersion()
-
hasFBOs
protected boolean hasFBOs()
-
hasShaders
protected boolean hasShaders()
-
hasNpotTexSupport
protected boolean hasNpotTexSupport()
-
hasAutoMipmapGenSupport
protected boolean hasAutoMipmapGenSupport()
-
hasFboMultisampleSupport
protected boolean hasFboMultisampleSupport()
-
hasPackedDepthStencilSupport
protected boolean hasPackedDepthStencilSupport()
-
hasAnisoSamplingSupport
protected boolean hasAnisoSamplingSupport()
-
hasSynchronization
protected boolean hasSynchronization()
-
hasPBOs
protected boolean hasPBOs()
-
hasReadBuffer
protected boolean hasReadBuffer()
-
hasDrawBuffer
protected boolean hasDrawBuffer()
-
maxSamples
protected int maxSamples()
-
getMaxTexUnits
protected int getMaxTexUnits()
-
allocateDirectByteBuffer
protected static ByteBuffer allocateDirectByteBuffer(int size)
-
allocateByteBuffer
protected static ByteBuffer allocateByteBuffer(int size)
-
allocateByteBuffer
protected static ByteBuffer allocateByteBuffer(byte[] arr)
-
updateByteBuffer
protected static ByteBuffer updateByteBuffer(ByteBuffer buf, byte[] arr, boolean wrap)
-
updateByteBuffer
protected static void updateByteBuffer(ByteBuffer buf, byte[] arr, int offset, int size)
-
getByteArray
protected static void getByteArray(ByteBuffer buf, byte[] arr)
-
putByteArray
protected static void putByteArray(ByteBuffer buf, byte[] arr)
-
fillByteBuffer
protected static void fillByteBuffer(ByteBuffer buf, int i0, int i1, byte val)
-
allocateDirectShortBuffer
protected static ShortBuffer allocateDirectShortBuffer(int size)
-
allocateShortBuffer
protected static ShortBuffer allocateShortBuffer(int size)
-
allocateShortBuffer
protected static ShortBuffer allocateShortBuffer(short[] arr)
-
updateShortBuffer
protected static ShortBuffer updateShortBuffer(ShortBuffer buf, short[] arr, boolean wrap)
-
updateShortBuffer
protected static void updateShortBuffer(ShortBuffer buf, short[] arr, int offset, int size)
-
getShortArray
protected static void getShortArray(ShortBuffer buf, short[] arr)
-
putShortArray
protected static void putShortArray(ShortBuffer buf, short[] arr)
-
fillShortBuffer
protected static void fillShortBuffer(ShortBuffer buf, int i0, int i1, short val)
-
allocateDirectIntBuffer
protected static IntBuffer allocateDirectIntBuffer(int size)
-
allocateIntBuffer
protected static IntBuffer allocateIntBuffer(int size)
-
allocateIntBuffer
protected static IntBuffer allocateIntBuffer(int[] arr)
-
updateIntBuffer
protected static void updateIntBuffer(IntBuffer buf, int[] arr, int offset, int size)
-
getIntArray
protected static void getIntArray(IntBuffer buf, int[] arr)
-
putIntArray
protected static void putIntArray(IntBuffer buf, int[] arr)
-
fillIntBuffer
protected static void fillIntBuffer(IntBuffer buf, int i0, int i1, int val)
-
allocateDirectFloatBuffer
protected static FloatBuffer allocateDirectFloatBuffer(int size)
-
allocateFloatBuffer
protected static FloatBuffer allocateFloatBuffer(int size)
-
allocateFloatBuffer
protected static FloatBuffer allocateFloatBuffer(float[] arr)
-
updateFloatBuffer
protected static FloatBuffer updateFloatBuffer(FloatBuffer buf, float[] arr, boolean wrap)
-
updateFloatBuffer
protected static void updateFloatBuffer(FloatBuffer buf, float[] arr, int offset, int size)
-
getFloatArray
protected static void getFloatArray(FloatBuffer buf, float[] arr)
-
putFloatArray
protected static void putFloatArray(FloatBuffer buf, float[] arr)
-
fillFloatBuffer
protected static void fillFloatBuffer(FloatBuffer buf, int i0, int i1, float val)
-
getFontAscent
protected abstract int getFontAscent(Object font)
-
getFontDescent
protected abstract int getFontDescent(Object font)
-
getTextWidth
protected abstract int getTextWidth(Object font, char[] buffer, int start, int stop)
-
createTessellator
protected abstract PGL.Tessellator createTessellator(PGL.TessellatorCallback callback)
-
tessError
protected String tessError(int err)
-
createFontOutline
protected abstract PGL.FontOutline createFontOutline(char ch, Object font)
-
flush
public abstract void flush()
-
finish
public abstract void finish()
-
hint
public abstract void hint(int target, int hint)
-
enable
public abstract void enable(int value)
-
disable
public abstract void disable(int value)
-
getBooleanv
public abstract void getBooleanv(int value, IntBuffer data)
-
getIntegerv
public abstract void getIntegerv(int value, IntBuffer data)
-
getFloatv
public abstract void getFloatv(int value, FloatBuffer data)
-
isEnabled
public abstract boolean isEnabled(int value)
-
getString
public abstract String getString(int name)
-
getError
public abstract int getError()
-
errorString
public abstract String errorString(int err)
-
genBuffers
public abstract void genBuffers(int n, IntBuffer buffers)
-
deleteBuffers
public abstract void deleteBuffers(int n, IntBuffer buffers)
-
bindBuffer
public abstract void bindBuffer(int target, int buffer)
-
bufferData
public abstract void bufferData(int target, int size, Buffer data, int usage)
-
bufferSubData
public abstract void bufferSubData(int target, int offset, int size, Buffer data)
-
isBuffer
public abstract void isBuffer(int buffer)
-
getBufferParameteriv
public abstract void getBufferParameteriv(int target, int value, IntBuffer data)
-
mapBuffer
public abstract ByteBuffer mapBuffer(int target, int access)
-
mapBufferRange
public abstract ByteBuffer mapBufferRange(int target, int offset, int length, int access)
-
unmapBuffer
public abstract void unmapBuffer(int target)
-
fenceSync
public abstract long fenceSync(int condition, int flags)
-
deleteSync
public abstract void deleteSync(long sync)
-
clientWaitSync
public abstract int clientWaitSync(long sync, int flags, long timeout)
-
depthRangef
public abstract void depthRangef(float n, float f)
-
viewport
public abstract void viewport(int x, int y, int w, int h)
-
viewportImpl
protected abstract void viewportImpl(int x, int y, int w, int h)
-
readPixels
public void readPixels(int x, int y, int width, int height, int format, int type, Buffer buffer)
-
readPixels
public void readPixels(int x, int y, int width, int height, int format, int type, long offset)
-
readPixelsImpl
protected abstract void readPixelsImpl(int x, int y, int width, int height, int format, int type, Buffer buffer)
-
readPixelsImpl
protected abstract void readPixelsImpl(int x, int y, int width, int height, int format, int type, long offset)
-
vertexAttrib1f
public abstract void vertexAttrib1f(int index, float value)
-
vertexAttrib2f
public abstract void vertexAttrib2f(int index, float value0, float value1)
-
vertexAttrib3f
public abstract void vertexAttrib3f(int index, float value0, float value1, float value2)
-
vertexAttrib4f
public abstract void vertexAttrib4f(int index, float value0, float value1, float value2, float value3)
-
vertexAttrib1fv
public abstract void vertexAttrib1fv(int index, FloatBuffer values)
-
vertexAttrib2fv
public abstract void vertexAttrib2fv(int index, FloatBuffer values)
-
vertexAttrib3fv
public abstract void vertexAttrib3fv(int index, FloatBuffer values)
-
vertexAttrib4fv
public abstract void vertexAttrib4fv(int index, FloatBuffer values)
-
vertexAttribPointer
public abstract void vertexAttribPointer(int index, int size, int type, boolean normalized, int stride, int offset)
-
enableVertexAttribArray
public abstract void enableVertexAttribArray(int index)
-
disableVertexAttribArray
public abstract void disableVertexAttribArray(int index)
-
drawArrays
public void drawArrays(int mode, int first, int count)
-
drawArraysImpl
public abstract void drawArraysImpl(int mode, int first, int count)
-
drawElements
public void drawElements(int mode, int count, int type, int offset)
-
drawElementsImpl
public abstract void drawElementsImpl(int mode, int count, int type, int offset)
-
lineWidth
public abstract void lineWidth(float width)
-
frontFace
public abstract void frontFace(int dir)
-
cullFace
public abstract void cullFace(int mode)
-
polygonOffset
public abstract void polygonOffset(float factor, float units)
-
pixelStorei
public abstract void pixelStorei(int pname, int param)
-
texImage2D
public abstract void texImage2D(int target, int level, int internalFormat, int width, int height, int border, int format, int type, Buffer data)
-
copyTexImage2D
public abstract void copyTexImage2D(int target, int level, int internalFormat, int x, int y, int width, int height, int border)
-
texSubImage2D
public abstract void texSubImage2D(int target, int level, int xOffset, int yOffset, int width, int height, int format, int type, Buffer data)
-
copyTexSubImage2D
public abstract void copyTexSubImage2D(int target, int level, int xOffset, int yOffset, int x, int y, int width, int height)
-
compressedTexImage2D
public abstract void compressedTexImage2D(int target, int level, int internalFormat, int width, int height, int border, int imageSize, Buffer data)
-
compressedTexSubImage2D
public abstract void compressedTexSubImage2D(int target, int level, int xOffset, int yOffset, int width, int height, int format, int imageSize, Buffer data)
-
texParameteri
public abstract void texParameteri(int target, int pname, int param)
-
texParameterf
public abstract void texParameterf(int target, int pname, float param)
-
texParameteriv
public abstract void texParameteriv(int target, int pname, IntBuffer params)
-
texParameterfv
public abstract void texParameterfv(int target, int pname, FloatBuffer params)
-
generateMipmap
public abstract void generateMipmap(int target)
-
genTextures
public abstract void genTextures(int n, IntBuffer textures)
-
deleteTextures
public abstract void deleteTextures(int n, IntBuffer textures)
-
getTexParameteriv
public abstract void getTexParameteriv(int target, int pname, IntBuffer params)
-
getTexParameterfv
public abstract void getTexParameterfv(int target, int pname, FloatBuffer params)
-
isTexture
public abstract boolean isTexture(int texture)
-
activeTexture
public void activeTexture(int texture)
-
activeTextureImpl
protected abstract void activeTextureImpl(int texture)
-
bindTexture
public void bindTexture(int target, int texture)
-
bindTextureImpl
protected abstract void bindTextureImpl(int target, int texture)
-
createShader
public abstract int createShader(int type)
-
shaderSource
public abstract void shaderSource(int shader, String source)
-
compileShader
public abstract void compileShader(int shader)
-
releaseShaderCompiler
public abstract void releaseShaderCompiler()
-
deleteShader
public abstract void deleteShader(int shader)
-
shaderBinary
public abstract void shaderBinary(int count, IntBuffer shaders, int binaryFormat, Buffer binary, int length)
-
createProgram
public abstract int createProgram()
-
attachShader
public abstract void attachShader(int program, int shader)
-
detachShader
public abstract void detachShader(int program, int shader)
-
linkProgram
public abstract void linkProgram(int program)
-
useProgram
public abstract void useProgram(int program)
-
deleteProgram
public abstract void deleteProgram(int program)
-
getActiveAttrib
public abstract String getActiveAttrib(int program, int index, IntBuffer size, IntBuffer type)
-
getAttribLocation
public abstract int getAttribLocation(int program, String name)
-
bindAttribLocation
public abstract void bindAttribLocation(int program, int index, String name)
-
getUniformLocation
public abstract int getUniformLocation(int program, String name)
-
getActiveUniform
public abstract String getActiveUniform(int program, int index, IntBuffer size, IntBuffer type)
-
uniform1i
public abstract void uniform1i(int location, int value)
-
uniform2i
public abstract void uniform2i(int location, int value0, int value1)
-
uniform3i
public abstract void uniform3i(int location, int value0, int value1, int value2)
-
uniform4i
public abstract void uniform4i(int location, int value0, int value1, int value2, int value3)
-
uniform1f
public abstract void uniform1f(int location, float value)
-
uniform2f
public abstract void uniform2f(int location, float value0, float value1)
-
uniform3f
public abstract void uniform3f(int location, float value0, float value1, float value2)
-
uniform4f
public abstract void uniform4f(int location, float value0, float value1, float value2, float value3)
-
uniform1iv
public abstract void uniform1iv(int location, int count, IntBuffer v)
-
uniform2iv
public abstract void uniform2iv(int location, int count, IntBuffer v)
-
uniform3iv
public abstract void uniform3iv(int location, int count, IntBuffer v)
-
uniform4iv
public abstract void uniform4iv(int location, int count, IntBuffer v)
-
uniform1fv
public abstract void uniform1fv(int location, int count, FloatBuffer v)
-
uniform2fv
public abstract void uniform2fv(int location, int count, FloatBuffer v)
-
uniform3fv
public abstract void uniform3fv(int location, int count, FloatBuffer v)
-
uniform4fv
public abstract void uniform4fv(int location, int count, FloatBuffer v)
-
uniformMatrix2fv
public abstract void uniformMatrix2fv(int location, int count, boolean transpose, FloatBuffer mat)
-
uniformMatrix3fv
public abstract void uniformMatrix3fv(int location, int count, boolean transpose, FloatBuffer mat)
-
uniformMatrix4fv
public abstract void uniformMatrix4fv(int location, int count, boolean transpose, FloatBuffer mat)
-
validateProgram
public abstract void validateProgram(int program)
-
isShader
public abstract boolean isShader(int shader)
-
getShaderiv
public abstract void getShaderiv(int shader, int pname, IntBuffer params)
-
getAttachedShaders
public abstract void getAttachedShaders(int program, int maxCount, IntBuffer count, IntBuffer shaders)
-
getShaderInfoLog
public abstract String getShaderInfoLog(int shader)
-
getShaderSource
public abstract String getShaderSource(int shader)
-
getShaderPrecisionFormat
public abstract void getShaderPrecisionFormat(int shaderType, int precisionType, IntBuffer range, IntBuffer precision)
-
getVertexAttribfv
public abstract void getVertexAttribfv(int index, int pname, FloatBuffer params)
-
getVertexAttribiv
public abstract void getVertexAttribiv(int index, int pname, IntBuffer params)
-
getVertexAttribPointerv
public abstract void getVertexAttribPointerv(int index, int pname, ByteBuffer data)
-
getUniformfv
public abstract void getUniformfv(int program, int location, FloatBuffer params)
-
getUniformiv
public abstract void getUniformiv(int program, int location, IntBuffer params)
-
isProgram
public abstract boolean isProgram(int program)
-
getProgramiv
public abstract void getProgramiv(int program, int pname, IntBuffer params)
-
getProgramInfoLog
public abstract String getProgramInfoLog(int program)
-
scissor
public abstract void scissor(int x, int y, int w, int h)
-
sampleCoverage
public abstract void sampleCoverage(float value, boolean invert)
-
stencilFunc
public abstract void stencilFunc(int func, int ref, int mask)
-
stencilFuncSeparate
public abstract void stencilFuncSeparate(int face, int func, int ref, int mask)
-
stencilOp
public abstract void stencilOp(int sfail, int dpfail, int dppass)
-
stencilOpSeparate
public abstract void stencilOpSeparate(int face, int sfail, int dpfail, int dppass)
-
depthFunc
public abstract void depthFunc(int func)
-
blendEquation
public abstract void blendEquation(int mode)
-
blendEquationSeparate
public abstract void blendEquationSeparate(int modeRGB, int modeAlpha)
-
blendFunc
public abstract void blendFunc(int src, int dst)
-
blendFuncSeparate
public abstract void blendFuncSeparate(int srcRGB, int dstRGB, int srcAlpha, int dstAlpha)
-
blendColor
public abstract void blendColor(float red, float green, float blue, float alpha)
-
colorMask
public abstract void colorMask(boolean r, boolean g, boolean b, boolean a)
-
depthMask
public abstract void depthMask(boolean mask)
-
stencilMask
public abstract void stencilMask(int mask)
-
stencilMaskSeparate
public abstract void stencilMaskSeparate(int face, int mask)
-
clearColor
public abstract void clearColor(float r, float g, float b, float a)
-
clearDepth
public abstract void clearDepth(float d)
-
clearStencil
public abstract void clearStencil(int s)
-
clear
public abstract void clear(int buf)
-
bindFramebuffer
public void bindFramebuffer(int target, int framebuffer)
-
bindFramebufferImpl
protected abstract void bindFramebufferImpl(int target, int framebuffer)
-
deleteFramebuffers
public abstract void deleteFramebuffers(int n, IntBuffer framebuffers)
-
genFramebuffers
public abstract void genFramebuffers(int n, IntBuffer framebuffers)
-
bindRenderbuffer
public abstract void bindRenderbuffer(int target, int renderbuffer)
-
deleteRenderbuffers
public abstract void deleteRenderbuffers(int n, IntBuffer renderbuffers)
-
genRenderbuffers
public abstract void genRenderbuffers(int n, IntBuffer renderbuffers)
-
renderbufferStorage
public abstract void renderbufferStorage(int target, int internalFormat, int width, int height)
-
framebufferRenderbuffer
public abstract void framebufferRenderbuffer(int target, int attachment, int rendbuferfTarget, int renderbuffer)
-
framebufferTexture2D
public abstract void framebufferTexture2D(int target, int attachment, int texTarget, int texture, int level)
-
checkFramebufferStatus
public abstract int checkFramebufferStatus(int target)
-
isFramebuffer
public abstract boolean isFramebuffer(int framebuffer)
-
getFramebufferAttachmentParameteriv
public abstract void getFramebufferAttachmentParameteriv(int target, int attachment, int pname, IntBuffer params)
-
isRenderbuffer
public abstract boolean isRenderbuffer(int renderbuffer)
-
getRenderbufferParameteriv
public abstract void getRenderbufferParameteriv(int target, int pname, IntBuffer params)
-
blitFramebuffer
public abstract void blitFramebuffer(int srcX0, int srcY0, int srcX1, int srcY1, int dstX0, int dstY0, int dstX1, int dstY1, int mask, int filter)
-
renderbufferStorageMultisample
public abstract void renderbufferStorageMultisample(int target, int samples, int format, int width, int height)
-
readBuffer
public abstract void readBuffer(int buf)
-
drawBuffer
public abstract void drawBuffer(int buf)
-
-