protected override void CreateNative()
 {
     glDevice           = (OpenTK20Device)device;
     nativeVertexBuffer = glDevice.CreateVertexBuffer(maxNumberOfVertices * vertexSize, OpenGL20BufferMode.Stream);
     if (nativeVertexBuffer == OpenTK20Device.InvalidHandle)
     {
         throw new UnableToCreateOpenGLGeometry();
     }
     if (UsesIndexBuffer)
     {
         nativeIndexBuffer = glDevice.CreateIndexBuffer(maxNumberOfIndices * indexSize, OpenGL20BufferMode.Stream);
     }
 }
Ejemplo n.º 2
0
 private OpenGL20Image(ImageCreationData data, OpenTK20Device device)
     : base(data)
 {
     this.device = device;
     CreateHandleAndSetDefaultSamplerState();
 }
Ejemplo n.º 3
0
 protected OpenGL20Image(string contentName, OpenTK20Device device)
     : base(contentName)
 {
     this.device = device;
     CreateHandleAndSetDefaultSamplerState();
 }
Ejemplo n.º 4
0
 public OpenTKShader(ShaderCreationData data, OpenTK20Device device)
     : base(data)
 {
     this.device = device;
     TryCreateShader();
 }
Ejemplo n.º 5
0
 public OpenTKShader(ShaderWithFormatCreationData creationData, OpenTK20Device device)
     : this((ShaderCreationData)creationData, device)
 {
 }
 public OpenGL20ScreenshotCapturer(Device device, Window window)
 {
     this.device = (OpenTK20Device)device;
     this.window = window;
 }
Ejemplo n.º 7
0
 private OpenGL20Geometry(GeometryCreationData creationData, OpenTK20Device device)
     : base(creationData)
 {
     this.device = device;
 }
Ejemplo n.º 8
0
 protected OpenGL20Geometry(string contentName, OpenTK20Device device)
     : base(contentName)
 {
     this.device = device;
 }