[rcore] add GetDisplayWidth() and GetDisplayHeight()
This commit is contained in:
parent
fbdf5e4fd2
commit
ace5d857f4
|
|
@ -999,6 +999,8 @@ RLAPI void SetWindowSize(int width, int height); // Set window
|
||||||
RLAPI void SetWindowOpacity(float opacity); // Set window opacity [0.0f..1.0f]
|
RLAPI void SetWindowOpacity(float opacity); // Set window opacity [0.0f..1.0f]
|
||||||
RLAPI void SetWindowFocused(void); // Set window focused
|
RLAPI void SetWindowFocused(void); // Set window focused
|
||||||
RLAPI void *GetWindowHandle(void); // Get native window handle
|
RLAPI void *GetWindowHandle(void); // Get native window handle
|
||||||
|
RLAPI int GetDisplayWidth(void); // Get display width
|
||||||
|
RLAPI int GetDisplayHeight(void); // Get display height
|
||||||
RLAPI int GetScreenWidth(void); // Get current screen width
|
RLAPI int GetScreenWidth(void); // Get current screen width
|
||||||
RLAPI int GetScreenHeight(void); // Get current screen height
|
RLAPI int GetScreenHeight(void); // Get current screen height
|
||||||
RLAPI int GetRenderWidth(void); // Get current render width (it considers HiDPI)
|
RLAPI int GetRenderWidth(void); // Get current render width (it considers HiDPI)
|
||||||
|
|
|
||||||
12
src/rcore.c
12
src/rcore.c
|
|
@ -819,6 +819,18 @@ bool IsWindowState(unsigned int flag)
|
||||||
return ((CORE.Window.flags & flag) > 0);
|
return ((CORE.Window.flags & flag) > 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Get display width
|
||||||
|
int GetDisplayWidth(void)
|
||||||
|
{
|
||||||
|
return CORE.Window.display.width;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Get display height
|
||||||
|
int GetDisplayHeight(void)
|
||||||
|
{
|
||||||
|
return CORE.Window.display.height;
|
||||||
|
}
|
||||||
|
|
||||||
// Get current screen width
|
// Get current screen width
|
||||||
int GetScreenWidth(void)
|
int GetScreenWidth(void)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user