Texture2D.cs 616 B

12345678910111213141516
  1. using System;
  2. using System.Runtime.CompilerServices;
  3. namespace BansheeEngine
  4. {
  5. public sealed class Texture2D : Resource
  6. {
  7. public Texture2D(TextureFormat format, int width, int height, bool hasMipmaps = false, bool gammaCorrection = false)
  8. {
  9. Internal_CreateInstance(this, format, width, height, hasMipmaps, gammaCorrection);
  10. }
  11. [MethodImpl(MethodImplOptions.InternalCall)]
  12. private static extern void Internal_CreateInstance(Texture2D instance, TextureFormat format, int width, int height, bool hasMipmaps, bool gammaCorrection);
  13. }
  14. }