More correct, still doesn't work.
This commit is contained in:
@@ -283,6 +283,7 @@ namespace OpenRA.GlRenderer
|
||||
|
||||
public IVertexBuffer<Vertex> CreateVertexBuffer(int size) { return new VertexBuffer<Vertex>(this, size); }
|
||||
public IIndexBuffer CreateIndexBuffer(int size) { return new IndexBuffer(this, size); }
|
||||
public ITexture CreateTexture() { return new Texture(this); }
|
||||
public ITexture CreateTexture(Bitmap bitmap) { return new Texture(this, bitmap); }
|
||||
public IShader CreateShader(Stream stream) { return new Shader(this, stream); }
|
||||
}
|
||||
|
||||
@@ -20,7 +20,13 @@ namespace OpenRA.GlRenderer
|
||||
public class Texture : ITexture
|
||||
{
|
||||
internal int texture;
|
||||
|
||||
|
||||
public Texture(GraphicsDevice dev)
|
||||
{
|
||||
Gl.glGenTextures(1, out texture);
|
||||
GraphicsDevice.CheckGlError();
|
||||
}
|
||||
|
||||
public Texture(GraphicsDevice dev, Bitmap bitmap)
|
||||
{
|
||||
Gl.glGenTextures(1, out texture);
|
||||
|
||||
Reference in New Issue
Block a user