FileLoader.odin

UnloadTexture

UnloadTexture (texture: ^sdl2.Texture)

Frees an SDL2 allocated texture

Parameters:
  • texture: The texture to free

LoadEmbeddedBMP

LoadEmbeddedBMP (cxt: RenderContext, data: []byte)

Loads a BMP image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedCUR

LoadEmbeddedCUR (cxt: RenderContext, data: []byte)

Loads a CUR image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedGIF

LoadEmbeddedGIF (cxt: RenderContext, data: []byte)

Loads a GIF image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedICO

LoadEmbeddedICO (cxt: RenderContext, data: []byte)

Loads a ICO image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedJPEG

LoadEmbeddedJPEG (cxt: RenderContext, data: []byte)

Loads a JPEG image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedLBM

LoadEmbeddedLBM (cxt: RenderContext, data: []byte)

Loads a LBM image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedPCX

LoadEmbeddedPCX (cxt: RenderContext, data: []byte)

Loads a PCX image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedPNG

LoadEmbeddedPNG (cxt: RenderContext, data: []byte)

Loads a PNG image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedPNM

LoadEmbeddedPNM (cxt: RenderContext, data: []byte)

Loads a PNM image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedSVG

LoadEmbeddedSVG (cxt: RenderContext, data: string)

Loads a SVG image from an SVG code string

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The string of SVG code
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedTGA

LoadEmbeddedTGA (cxt: RenderContext, data: []byte)

Loads a TGA image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedXCF

LoadEmbeddedXCF (cxt: RenderContext, data: []byte)

Loads a XCF image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedXPM

LoadEmbeddedXPM (cxt: RenderContext, data: []byte)

Loads a XPM image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedXV

LoadEmbeddedXV (cxt: RenderContext, data: []byte)

Loads a XV image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadEmbeddedWebP

LoadEmbeddedWebP (cxt: RenderContext, data: []byte)

Loads a WebP image from an array of bytes

Parameters:
  • cxt: The rendering context used to create the texture
  • data: The array of bytes to load
Returns: An SDL texture to pass to DrawTexture

LoadBMPFile

LoadBMPFile (cxt: RenderContext, file_path: cstring)

Loads a BMP image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadCURFile

LoadCURFile (cxt: RenderContext, file_path: cstring)

Loads a CUR image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadGIFFile

LoadGIFFile (cxt: RenderContext, file_path: cstring)

Loads a GIF image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadICOFile

LoadICOFile (cxt: RenderContext, file_path: cstring)

Loads a ICO image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadJPEGFile

LoadJPEGFile (cxt: RenderContext, file_path: cstring)

Loads a JPEG image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadLBMFile

LoadLBMFile (cxt: RenderContext, file_path: cstring)

Loads a LBM image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadPCXFile

LoadPCXFile (cxt: RenderContext, file_path: cstring)

Loads a PCX image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadPNGFile

LoadPNGFile (cxt: RenderContext, file_path: cstring)

Loads a PNG image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadPNMFile

LoadPNMFile (cxt: RenderContext, file_path: cstring)

Loads a PNM image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadSVGFile

LoadSVGFile (cxt: RenderContext, file_path: cstring)

Loads a SVG image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadTGAFile

LoadTGAFile (cxt: RenderContext, file_path: cstring)

Loads a TGA image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadXCFFile

LoadXCFFile (cxt: RenderContext, file_path: cstring)

Loads a XCF image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadXPMFile

LoadXPMFile (cxt: RenderContext, file_path: cstring)

Loads a XPM image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadXVFile

LoadXVFile (cxt: RenderContext, file_path: cstring)

Loads a XV image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture

LoadWebPFile

LoadWebPFile (cxt: RenderContext, file_path: cstring)

Loads a WebP image from a file

Parameters:
  • cxt: The rendering context used to create the texture
  • file_path: The path to the image file
Returns: An SDL texture to pass to DrawTexture