Added SetWindowOpacity()
This commit is contained in:
parent
ef21d3df75
commit
c2a70b3f68
|
|
@ -925,6 +925,7 @@ RLAPI void SetWindowPosition(int x, int y); // Set window
|
||||||
RLAPI void SetWindowMonitor(int monitor); // Set monitor for the current window (fullscreen mode)
|
RLAPI void SetWindowMonitor(int monitor); // Set monitor for the current window (fullscreen mode)
|
||||||
RLAPI void SetWindowMinSize(int width, int height); // Set window minimum dimensions (for FLAG_WINDOW_RESIZABLE)
|
RLAPI void SetWindowMinSize(int width, int height); // Set window minimum dimensions (for FLAG_WINDOW_RESIZABLE)
|
||||||
RLAPI void SetWindowSize(int width, int height); // Set window dimensions
|
RLAPI void SetWindowSize(int width, int height); // Set window dimensions
|
||||||
|
RLAPI void SetWindowOpacity(float opacity); // Set window opacity, value opacity is between 0.0 and 1.0 (only PLATFORM_DESKTOP)
|
||||||
RLAPI void *GetWindowHandle(void); // Get native window handle
|
RLAPI void *GetWindowHandle(void); // Get native window handle
|
||||||
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
|
||||||
|
|
|
||||||
10
src/rcore.c
10
src/rcore.c
|
|
@ -1534,6 +1534,16 @@ void SetWindowSize(int width, int height)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Set window opacity, value opacity is between 0.0 and 1.0
|
||||||
|
void SetWindowOpacity (float opacity)
|
||||||
|
{
|
||||||
|
#if defined(PLATFORM_DESKTOP)
|
||||||
|
if (opacity >= 1.0) opacity = 1.0;
|
||||||
|
else if (opacity <= 0.0) opacity = 0.0;
|
||||||
|
glfwSetWindowOpacity(CORE.Window.handle, opacity);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
// Get current screen width
|
// Get current screen width
|
||||||
int GetScreenWidth(void)
|
int GetScreenWidth(void)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user