Added GetScreenSize function to return screen width & height as a Vector2.
This commit is contained in:
parent
890058abcd
commit
e6e6b04d13
|
|
@ -986,6 +986,7 @@ RLAPI void SetWindowFocused(void); // Set window
|
|||
RLAPI void *GetWindowHandle(void); // Get native window handle
|
||||
RLAPI int GetScreenWidth(void); // Get current screen width
|
||||
RLAPI int GetScreenHeight(void); // Get current screen height
|
||||
RLAPI Vector2 GetScreenSize(void); // Get current screen width and height as a Vector2
|
||||
RLAPI int GetRenderWidth(void); // Get current render width (it considers HiDPI)
|
||||
RLAPI int GetRenderHeight(void); // Get current render height (it considers HiDPI)
|
||||
RLAPI int GetMonitorCount(void); // Get number of connected monitors
|
||||
|
|
|
|||
|
|
@ -762,6 +762,12 @@ int GetScreenHeight(void)
|
|||
return CORE.Window.screen.height;
|
||||
}
|
||||
|
||||
// Get current screen width and height as a Vector2
|
||||
Vector2 GetScreenSize(void)
|
||||
{
|
||||
return (Vector2){ (float)CORE.Window.screen.width, (float)CORE.Window.screen.height };
|
||||
}
|
||||
|
||||
// Get current render width which is equal to screen width*dpi scale
|
||||
int GetRenderWidth(void)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user