FormatInfo.cs 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. using OpenTK.Graphics.OpenGL;
  2. namespace Ryujinx.Graphics.OpenGL
  3. {
  4. struct FormatInfo
  5. {
  6. public int Components { get; }
  7. public bool Normalized { get; }
  8. public bool Scaled { get; }
  9. public PixelInternalFormat PixelInternalFormat { get; }
  10. public PixelFormat PixelFormat { get; }
  11. public PixelType PixelType { get; }
  12. public bool IsCompressed { get; }
  13. public FormatInfo(
  14. int components,
  15. bool normalized,
  16. bool scaled,
  17. All pixelInternalFormat,
  18. PixelFormat pixelFormat,
  19. PixelType pixelType)
  20. {
  21. Components = components;
  22. Normalized = normalized;
  23. Scaled = scaled;
  24. PixelInternalFormat = (PixelInternalFormat)pixelInternalFormat;
  25. PixelFormat = pixelFormat;
  26. PixelType = pixelType;
  27. IsCompressed = false;
  28. }
  29. public FormatInfo(int components, bool normalized, bool scaled, All pixelFormat)
  30. {
  31. Components = components;
  32. Normalized = normalized;
  33. Scaled = scaled;
  34. PixelInternalFormat = 0;
  35. PixelFormat = (PixelFormat)pixelFormat;
  36. PixelType = 0;
  37. IsCompressed = true;
  38. }
  39. }
  40. }