sdlSetWindowSize function

void sdlSetWindowSize(
  1. Pointer<SdlWindow> window,
  2. int w,
  3. int h
)

Set the size of a window's client area.

The window size in screen coordinates may differ from the size in pixels, if the window was created with SDL_WINDOW_ALLOW_HIGHDPI on a platform with high-dpi support (e.g. iOS or macOS). Use SDL_GL_GetDrawableSize() or SDL_GetRendererOutputSize() to get the real client area size in pixels.

Fullscreen windows automatically match the size of the display mode, and you should use SDL_SetWindowDisplayMode() to change their size.

\param window the window to change \param w the width of the window in pixels, in screen coordinates, must be

0 \param h the height of the window in pixels, in screen coordinates, must be 0

\since This function is available since SDL 2.0.0.

\sa SDL_GetWindowSize \sa SDL_SetWindowDisplayMode

extern DECLSPEC void SDLCALL SDL_SetWindowSize(SDL_Window * window, int w, int h)

Implementation

void sdlSetWindowSize(Pointer<SdlWindow> window, int w, int h) {
  final sdlSetWindowSizeLookupFunction = libSdl2.lookupFunction<
      Void Function(Pointer<SdlWindow> window, Int32 w, Int32 h),
      void Function(
          Pointer<SdlWindow> window, int w, int h)>('SDL_SetWindowSize');
  return sdlSetWindowSizeLookupFunction(window, w, h);
}