Save an SDL_Surface into JPEG image data, via an SDL_RWops.
Defined in <SDL_image.h>
int IMG_SaveJPG_RW(SDL_Surface *surface, SDL_RWops *dst, int freedst, int quality);
SDL_Surface * | surface | the SDL surface to save. |
SDL_RWops * | dst | the SDL_RWops to save the image data to. |
(int) Returns 0 if successful, -1 on error.
If you just want to save to a filename, you can use IMG_SaveJPG() instead.
This function is available since SDL_image 2.0.2.