libmx2 2.2.1
C++20 multimedia and game-engine library (SDL2 / OpenGL / Vulkan)
Loading...
Searching...
No Matches
jpeg.cpp File Reference

Implementation of jpeg::LoadJPEG and jpeg::SaveJPEG utilities. More...

#include "config.h"
#include <stdio.h>
#include <jpeglib.h>
#include <setjmp.h>
#include "SDL.h"
Include dependency graph for jpeg.cpp:

Go to the source code of this file.

Classes

struct  jpeg::my_error_mgr

Namespaces

namespace  jpeg
 Utilities for loading and saving JPEG images.

Typedefs

typedef struct my_error_mgr * jpeg::my_error_ptr

Functions

void jpeg::my_error_exit (j_common_ptr cinfo)
SDL_Surface * jpeg::LoadJPEG (const char *src)
 Load a JPEG file into an SDL_Surface.
bool jpeg::SaveJPEG (SDL_Renderer *renderer, SDL_Texture *texture, const char *filename, int quality=90)
 Save an SDL_Texture to a JPEG file.

Detailed Description

Implementation of jpeg::LoadJPEG and jpeg::SaveJPEG utilities.

Definition in file jpeg.cpp.