saveJPG

Wraps IMG_SaveJPG (from SDL_image 2.0.2) which saves a dsdl2.Surface image into a JPG file in the filesystem

@safe @trusted
static if(bindSDLImage)
static if(sdlImageSupport >= SDLImageSupport.v2_0_2)
void
saveJPG
(,
string file
,
ubyte quality
)

Parameters

surface Surface

given dsdl2.Surface of the image to save

file string

target file path to save

quality ubyte

value ranging from 0 to 100 specifying the image quality compensating for compression

Throws

dsdl2.SDLException if failed to save

Meta