Function sdl2_sys::SDL_GetPlatform

source ·
pub unsafe extern "C" fn SDL_GetPlatform() -> *const c_char
Expand description

Get the name of the platform.

Here are the names returned for some (but not all) supported platforms:

  • “Windows”
  • “Mac OS X”
  • “Linux”
  • “iOS”
  • “Android”

\returns the name of the platform. If the correct platform name is not available, returns a string beginning with the text “Unknown”.

\since This function is available since SDL 2.0.0.