Files
Upsilon/ion/src/simulator/shared/platform.h
Émilie Feral 8b5caeb394 [ion] IonSimulatorLoadImage returns a Texture (otherwise the pixels data
which needs to be deleted when freeing the surface is hard to retrieve)
2020-09-30 17:30:34 +02:00

32 lines
783 B
C

#ifndef ION_SIMULATOR_PLATFORM_H
#define ION_SIMULATOR_PLATFORM_H
#include <SDL.h>
#include <stdbool.h>
#ifdef __cplusplus
extern "C" {
#endif
/* Those functions should be implemented per-platform.
* They are defined as C function for easier interop. */
SDL_Texture * IonSimulatorLoadImage(SDL_Renderer * renderer, const char * identifier, bool withTransparency, uint8_t alpha);
char * IonSimulatorGetLanguageCode();
#if EPSILON_SDL_SCREEN_ONLY
void IonSimulatorKeyboardKeyDown(int keyNumber);
void IonSimulatorKeyboardKeyUp(int keyNumber);
void IonSimulatorEventsPushEvent(int eventNumber);
#endif
bool IonSimulatorSDLKeyDetectedByScan(SDL_Scancode key);
void IonSimulatorCallbackDidRefresh();
void IonSimulatorCallbackDidScanKeyboard();
#ifdef __cplusplus
}
#endif
#endif