LarsBrubaker's picture

Agg-Sharp a c# port of AGG with GL Acceleration

Just wanted to post that we (Reflexive inc. http://www.reflexive-inc.com) are creating a c# version of AGG, originally written by Maxim Shemanarev in C++ (http://www.antigrain.com).

It is currently quite functional and the SVN builds have a good bit of OpenGL support, including a polygon tessellator. There are many samples that show how the whole thing works and it is in active development, as we are planing to use it for shipping titles soon.

Currently I am looking at the possibility of using OpenTK for our hardware abstraction layer.

Hopefully there is some value in this to some of you.

Lars.


Inertia's picture

Enum: Framebuffer Objects (Version15) [done!]

Spec: http://www.opengl.org/registry/specs/EXT/framebuffer_object.txt

            // Old: void GL.Ext.GetFramebufferAttachmentParameter(All target, All attachment, All pname, out params);
            // New: void GL.Ext.GetFramebufferAttachmentParameter(FramebufferTarget target, FboAttachment attachment, FboPName pname, out params);
 
            // Old: All GL.Ext.CheckFramebufferStat(All target);
            // New: FBOErrorCode GL.Ext.CheckFramebufferStat(FramebufferTarget target);
 
            // note: these are 3 functions
            // Old: void GL.Ext.FramebufferTexture(1/2/3)D(All target, All attachment, All textarget, int texture, int level); 
            // New: void GL.Ext.FramebufferTexture(1/2/3)D(FramebufferTarget target, FboAttachment attachment, TextureTarget textarget, int texture, int level); 
            // using TextureTarget is a little errorprone, but avoids creating a new enum. 
 
            // Old: void GL.Ext.FramebufferRenderbuffer(All target, All attachment, All renderbuffertarget, int renderbuffer);

Inertia's picture

Enum Remains [done!]

This is a list of the last tokens i couldn't properly identify, and one Ati Extension where i'm not certain if it should be included at all.
Often it's mentioned that it has been added "somewhere", but theres no entry at "somewhere".

public enum Version12
        {
            MaxElementsVertices = ( (int) 0x80e8 ), //??
            MaxElementsIndices = ( (int) 0x80e9 ), //??
}
 
 public enum Version20
        {
            // partially: http://www.opengl.org/registry/specs/ATI/separate_stencil.txt
            StencilBackFunc = ( (int) 0x8800 ),
            StencilBackFail = ( (int) 0x8801 ),
            StencilBackPassDepthFail = ( (int) 0x8802 ),
            StencilBackPassDepthPass = ( (int) 0x8803 ),
            StencilBackRef = ( (int) 0x8ca3 ),
            StencilBackValueMask = ( (int) 0x8ca4 ),
            StencilBackWritemask = ( (int) 0x8ca5 ),
 
            AttachedShaders = ( (int) 0x8b85 ), // should both belong to ARB_shader_object, not listed?
            CurrentProgram = ( (int) 0x8b8d ), // CURRENT_PROGRAM				= 0x8B8D    # ARB_shader_objects (added for 2.0)
 
            PointSpriteCoordOrigin = ( (int) 0x8ca0 ),

Inertia's picture

Asm&GLSL Shader Tokens (part 2/2) [done!]

Part 1/2 of this topic is located at http://www.opentk.com/node/190

http://www.opengl.org/registry/specs/ARB/shader_objects.txt
http://www.opengl.org/registry/specs/ARB/fragment_shader.txt
http://www.opengl.org/registry/specs/ARB/vertex_shader.txt
http://www.opengl.org/registry/specs/ARB/fragment_program.txt
http://www.opengl.org/registry/specs/ARB/vertex_program.txt

        public enum AsmProgramTarget : int
        {
            FragmentProgram = 0x8804,
            VertexProgram = 0x8620,
            GeometryProgramNv = All.GeometryProgramNv,
        }
 
        public enum AsmProgramFormat : int
        {
            ProgramFormatAscii = (int) 0x8875, // was missing
        }
 
        public enum GetAsmProgramParameters : int
        {
            ProgramLength = 0x8627,
            ProgramFormat = 0x8876,
            ProgramBinding = 0x8677,
            ProgramInstructions = 0x88A0,
            MaxProgramInstructions = 0x88A1,
            ProgramNativeInstructions = 0x88A2,
            MaxProgramNativeInstructions = 0x88A3,
            ProgramTemporaries = 0x88A4,

Inertia's picture

Asm&GLSL Shader Functions (part 1/2) [done!]

Part 2/2 of this topic is located at http://www.opentk.com/node/191

http://www.opengl.org/registry/specs/ARB/shader_objects.txt
http://www.opengl.org/registry/specs/ARB/fragment_shader.txt
http://www.opengl.org/registry/specs/ARB/vertex_shader.txt
http://www.opengl.org/registry/specs/ARB/fragment_program.txt
http://www.opengl.org/registry/specs/ARB/vertex_program.txt

Assembly Program Functions. class GL.Arb

old: GL.Arb.ProgramString( ArbVertexProgram target, ArbVertexProgram format, XX, XX );
new: GL.Arb.ProgramString( AsmProgramTarget target, AsmProgramFormat format, XX, XX );
*
old: GL.Arb.BindProgram( ArbVertexProgram target, XX );
new: GL.Arb.BindProgram( AsmProgramTarget target, XX );
*
old: GL.Arb.ProgramEnvParameter4( ArbVertexProgram target, XX, XX );
new: GL.Arb.ProgramEnvParameter4( AsmProgramTarget target, XX, XX );
*
old: GL.Arb.ProgramLocalParameter4( ArbVertexProgram target, XX, XX );
new: GL.Arb.ProgramLocalParameter4( AsmProgramTarget target, XX, XX );
*