Package org.lwjgl.sdl

Class SDL_PixelFormatDetails

All Implemented Interfaces:
Pointer

public class SDL_PixelFormatDetails extends Struct<SDL_PixelFormatDetails>

 struct SDL_PixelFormatDetails {
     SDL_PixelFormat format;
     Uint8 bits_per_pixel;
     Uint8 bytes_per_pixel;
     Uint8 padding[2];
     Uint32 Rmask;
     Uint32 Gmask;
     Uint32 Bmask;
     Uint32 Amask;
     Uint8 Rbits;
     Uint8 Gbits;
     Uint8 Bbits;
     Uint8 Abits;
     Uint8 Rshift;
     Uint8 Gshift;
     Uint8 Bshift;
     Uint8 Ashift;
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • FORMAT

      public static final int FORMAT
      The struct member offsets.
    • BITS_PER_PIXEL

      public static final int BITS_PER_PIXEL
      The struct member offsets.
    • BYTES_PER_PIXEL

      public static final int BYTES_PER_PIXEL
      The struct member offsets.
    • PADDING

      public static final int PADDING
      The struct member offsets.
    • RMASK

      public static final int RMASK
      The struct member offsets.
    • GMASK

      public static final int GMASK
      The struct member offsets.
    • BMASK

      public static final int BMASK
      The struct member offsets.
    • AMASK

      public static final int AMASK
      The struct member offsets.
    • RBITS

      public static final int RBITS
      The struct member offsets.
    • GBITS

      public static final int GBITS
      The struct member offsets.
    • BBITS

      public static final int BBITS
      The struct member offsets.
    • ABITS

      public static final int ABITS
      The struct member offsets.
    • RSHIFT

      public static final int RSHIFT
      The struct member offsets.
    • GSHIFT

      public static final int GSHIFT
      The struct member offsets.
    • BSHIFT

      public static final int BSHIFT
      The struct member offsets.
    • ASHIFT

      public static final int ASHIFT
      The struct member offsets.
  • Constructor Details

    • SDL_PixelFormatDetails

      public SDL_PixelFormatDetails(ByteBuffer container)
      Creates a SDL_PixelFormatDetails instance at the current position of the specified ByteBuffer container. Changes to the buffer's content will be visible to the struct instance and vice versa.

      The created instance holds a strong reference to the container object.

  • Method Details

    • sizeof

      public int sizeof()
      Description copied from class: Struct
      Returns sizeof(struct).
      Specified by:
      sizeof in class Struct<SDL_PixelFormatDetails>
    • format

      public int format()
      Returns:
      the value of the format field.
    • bits_per_pixel

      public byte bits_per_pixel()
      Returns:
      the value of the bits_per_pixel field.
    • bytes_per_pixel

      public byte bytes_per_pixel()
      Returns:
      the value of the bytes_per_pixel field.
    • Rmask

      public int Rmask()
      Returns:
      the value of the Rmask field.
    • Gmask

      public int Gmask()
      Returns:
      the value of the Gmask field.
    • Bmask

      public int Bmask()
      Returns:
      the value of the Bmask field.
    • Amask

      public int Amask()
      Returns:
      the value of the Amask field.
    • Rbits

      public byte Rbits()
      Returns:
      the value of the Rbits field.
    • Gbits

      public byte Gbits()
      Returns:
      the value of the Gbits field.
    • Bbits

      public byte Bbits()
      Returns:
      the value of the Bbits field.
    • Abits

      public byte Abits()
      Returns:
      the value of the Abits field.
    • Rshift

      public byte Rshift()
      Returns:
      the value of the Rshift field.
    • Gshift

      public byte Gshift()
      Returns:
      the value of the Gshift field.
    • Bshift

      public byte Bshift()
      Returns:
      the value of the Bshift field.
    • Ashift

      public byte Ashift()
      Returns:
      the value of the Ashift field.
    • create

      public static SDL_PixelFormatDetails create(long address)
      Returns a new SDL_PixelFormatDetails instance for the specified memory address.
    • createSafe

      public static @Nullable SDL_PixelFormatDetails createSafe(long address)
      Like create, but returns null if address is NULL.
    • create

      public static SDL_PixelFormatDetails.Buffer create(long address, int capacity)
      Create a SDL_PixelFormatDetails.Buffer instance at the specified memory.
      Parameters:
      address - the memory address
      capacity - the buffer capacity
    • createSafe

      public static @Nullable SDL_PixelFormatDetails.Buffer createSafe(long address, int capacity)
      Like create, but returns null if address is NULL.
    • nformat

      public static int nformat(long struct)
      Unsafe version of format().
    • nbits_per_pixel

      public static byte nbits_per_pixel(long struct)
      Unsafe version of bits_per_pixel().
    • nbytes_per_pixel

      public static byte nbytes_per_pixel(long struct)
      Unsafe version of bytes_per_pixel().
    • npadding

      public static ByteBuffer npadding(long struct)
    • npadding

      public static byte npadding(long struct, int index)
    • nRmask

      public static int nRmask(long struct)
      Unsafe version of Rmask().
    • nGmask

      public static int nGmask(long struct)
      Unsafe version of Gmask().
    • nBmask

      public static int nBmask(long struct)
      Unsafe version of Bmask().
    • nAmask

      public static int nAmask(long struct)
      Unsafe version of Amask().
    • nRbits

      public static byte nRbits(long struct)
      Unsafe version of Rbits().
    • nGbits

      public static byte nGbits(long struct)
      Unsafe version of Gbits().
    • nBbits

      public static byte nBbits(long struct)
      Unsafe version of Bbits().
    • nAbits

      public static byte nAbits(long struct)
      Unsafe version of Abits().
    • nRshift

      public static byte nRshift(long struct)
      Unsafe version of Rshift().
    • nGshift

      public static byte nGshift(long struct)
      Unsafe version of Gshift().
    • nBshift

      public static byte nBshift(long struct)
      Unsafe version of Bshift().
    • nAshift

      public static byte nAshift(long struct)
      Unsafe version of Ashift().