Browse Source

Swap the two parameters

pull/310/head
Wilhem Barbier 7 years ago
parent
commit
3fe268d004
2 changed files with 2 additions and 2 deletions
  1. +1
    -1
      src/raylib.h
  2. +1
    -1
      src/textures.c

+ 1
- 1
src/raylib.h View File

@ -849,7 +849,7 @@ RLAPI void UnloadRenderTexture(RenderTexture2D target);
RLAPI Color *GetImageData(Image image); // Get pixel data from image as a Color struct array
RLAPI Image GetTextureData(Texture2D texture); // Get pixel data from GPU texture and return an Image
RLAPI void UpdateTexture(Texture2D texture, const void *pixels); // Update GPU texture with new data
RLAPI void SaveImageAs(n">Image image, const char *fileName); // Save image to a PNG file
RLAPI void SaveImageAs(const char *fileName, Image image); // Save image to a PNG file
// Image manipulation functions
RLAPI void ImageToPOT(Image *image, Color fillColor); // Convert image to POT (power-of-two)

+ 1
- 1
src/textures.c View File

@ -554,7 +554,7 @@ void UpdateTexture(Texture2D texture, const void *pixels)
}
// Save image to a PNG file
void SaveImageAs(n">Image image, const char *fileName)
void SaveImageAs(k">const char* fileName, Image image)
{
#if defined(PLATFORM_DESKTOP) || defined(PLATFORM_RPI)
unsigned char* imgData = (unsigned char*)GetImageData(image); // this works since Color is just a container for the RGBA values

Loading…
Cancel
Save