Skip to main content

SDL_TimeToDateTime

Function SDL_TimeToDateTime 

Source
pub unsafe extern "C" fn SDL_TimeToDateTime(
    ticks: SDL_Time,
    dt: *mut SDL_DateTime,
    localTime: bool,
) -> bool
Expand description

Converts an SDL_Time in nanoseconds since the epoch to a calendar time in the SDL_DateTime format.

Parameter: ticks the SDL_Time to be converted. Parameter: dt the resulting SDL_DateTime. Parameter: localTime the resulting SDL_DateTime will be expressed in local time if true, otherwise it will be in Universal Coordinated Time (UTC). Returns: true on success or false on failure; call SDL_GetError() for more information.

Thread Safety: It is safe to call this function from any thread.

Available Since: This function is available since SDL 3.2.0.