/** * @param glContext * the context for which this shader program was created. * @param fragmentShaderSource * the program to attach and link against this open gl program. * @return the id of the linked vertex shader. * @throws RuntimeException * if the shader could not be compiled or linked. */ public int createFragmentShader( GL glContext, String fragmentShaderSource ) throws RuntimeException { LOG.debug( "Adding fragment shader source: " + fragmentShaderSource ); return compileShader( glContext, GL.GL_FRAGMENT_SHADER, fragmentShaderSource ); }
/** * @param glContext * the context for which this shader program was created. * @param vertexShaderSource * the program to attach and link against this open gl program. * @return the id of the linked vertex shader. * @throws RuntimeException * if the shader could not be compiled or linked. */ public int createVertexShader( GL glContext, String vertexShaderSource ) throws RuntimeException { LOG.debug( "Adding vertex shader source: " + vertexShaderSource ); return compileShader( glContext, GL.GL_VERTEX_SHADER, vertexShaderSource ); }