internal Texture(IntPtr ptr) { TexturePtr = SDL_CreateTextureFromSurface(Graphics.RendererPtr, ptr); SDL_FreeSurface(ptr); texture = SDL_Texture.FromPointer(TexturePtr); texture = SDL_Texture.FromPointer(TexturePtr); }
public Texture(string file) { this.file = file; TexturePtr = TextureManager.LoadTexture(file); texture = SDL_Texture.FromPointer(TexturePtr); }
public Texture(int width, int height) { TexturePtr = SDL_CreateTexture(Graphics.RendererPtr, (uint)PixelFormat.ARGB8888, (int)TextureAccess.TARGET, width, height); texture = SDL_Texture.FromPointer(TexturePtr); }