示例#1
0
        public GLTexture2D GetColorBuffer(ColorBufferAttachPoint attachPoint)
        {
            if (!fColorBuffers.ContainsKey(attachPoint))
                return null;

            else
                return fColorBuffers[attachPoint];
        }
示例#2
0
        public void FramebufferTexture3D(int target, ColorBufferAttachPoint attachment, int textarget, int textureID, int level, int zoffset)
        {
            bool result = false;

            if (null == glFramebufferTexture3DEXT)
                glFramebufferTexture3DEXT = Extensions.LoadExtension("glFramebufferTexture3DEXT", typeof(DglFramebufferTexture3DEXT_IIIIII), ref result) as DglFramebufferTexture3DEXT_IIIIII;

            if (null != glFramebufferTexture3DEXT)
                glFramebufferTexture3DEXT(target, (int)attachment, textarget, textureID, level, zoffset);
        }
示例#3
0
        public void AttachColorBuffer(GLTexture2D colorbuffer, ColorBufferAttachPoint attachPosition)
        {
            fWidth = colorbuffer.Width;
            fHeight = colorbuffer.Height;

            Bind();
            colorbuffer.Bind();

            fFrameBuffer.AttachColorBuffer(colorbuffer, attachPosition);
            fColorBuffers.Add(attachPosition, colorbuffer);
        }
示例#4
0
 public void Attach1DTexture(ColorBufferAttachPoint attachType, GLTexture2D tex)
 {
     GI.FramebufferTexture1D(gl.GL_FRAMEBUFFER_EXT, attachType, gl.GL_TEXTURE_1D, (int)tex.TextureID, 0);
 }
示例#5
0
 public void AttachColorBuffer(GLTexture2D colorbuffer, ColorBufferAttachPoint attachPosition)
 {
     GI.FramebufferTexture2D(gl.GL_FRAMEBUFFER_EXT, attachPosition, gl.GL_TEXTURE_2D, (int)colorbuffer.TextureID, 0);
 }
示例#6
0
 public void Attach3DTexture(GLTexture2D tex, ColorBufferAttachPoint attachType)
 {
     GI.FramebufferTexture3D(gl.GL_FRAMEBUFFER_EXT, attachType, gl.GL_TEXTURE_3D, (int)tex.TextureID, 0, 0);
 }
示例#7
0
 public void Attach3DTexture(GLTexture2D tex, ColorBufferAttachPoint attachType, int mipLevel, int zOffset)
 {
     GI.FramebufferTexture3D(gl.GL_FRAMEBUFFER_EXT, attachType, gl.GL_TEXTURE_3D, (int)tex.TextureID, mipLevel, zOffset);
 }
示例#8
0
 public void Attach2DTexture(ColorBufferAttachPoint attachType, GLTexture2D tex, int mipLevel)
 {
     GI.FramebufferTexture2D(gl.GL_FRAMEBUFFER_EXT, attachType, gl.GL_TEXTURE_2D, (int)tex.TextureID, mipLevel);
 }