Nebula
Loading...
Searching...
No Matches
window.h
Go to the documentation of this file.
1#pragma once
2//------------------------------------------------------------------------------
9//------------------------------------------------------------------------------
10#include "ids/id.h"
11#include "ids/idpool.h"
15#include "util/stringatom.h"
16#include "util/blob.h"
17
18#if defined(CreateWindow)
19#undef CreateWindow
20#endif
21
22namespace CoreGraphics
23{
24
26struct TextureId;
27struct SwapchainId;
28
41
43const WindowId CreateWindow(const WindowCreateInfo& info);
45const WindowId EmbedWindow(const Util::Blob& windowData);
47void DestroyWindow(const WindowId id);
48
50void WindowResize(const WindowId id, SizeT newWidth, SizeT newHeight);
52void WindowSetTitle(const WindowId id, const Util::String& title);
54void WindowMakeCurrent(const WindowId id);
56void WindowPresent(const WindowId id, const IndexT frameIndex);
58void WindowPollEvents();
60void WindowNewFrame(const WindowId id);
62void WindowApplyFullscreen(const WindowId id, Adapter::Code monitor, bool b);
64void WindowSetCursorVisible(const WindowId id, bool b);
66void WindowSetCursorLocked(const WindowId id, bool b);
67
73const bool WindowIsFullscreen(const WindowId id);
75const bool WindowIsDecorated(const WindowId id);
77const bool WindowIsResizable(const WindowId id);
86
87} // CoreGraphics
Code
enum
Definition adapter.h:23
Code
enum
Definition antialiasquality.h:24
Describe a fullscreen display mode or window dimensions.
Definition displaymode.h:19
The Util::Blob class encapsulates a chunk of raw memory into a C++ object which can be copied,...
Definition blob.h:22
A StringAtom.
Definition stringatom.h:22
#define ID_24_8_TYPE(x)
Definition id.h:132
Acceleration structures are used to enable ray tracing on the GPU by dividing the scene into a BVH.
Definition accelerationstructure.h:24
const bool WindowIsFullscreen(const WindowId id)
get if fullscreen
Definition glfwwindow.cc:590
Math::vec2 WindowGetContentScale(const WindowId id)
retrieve window content scaling (ratio between current DPI and platform default DPI)
void WindowPollEvents()
poll events for window
Definition glfwwindow.cc:531
const bool WindowIsResizable(const WindowId id)
get if we are allowed to switch the display mode
Definition glfwwindow.cc:608
void WindowNewFrame(const WindowId id)
Do new frame stuff for window.
Definition glfwwindow.cc:540
WindowId CurrentWindow
Definition glfwwindow.cc:22
void WindowPresent(const WindowId id, const IndexT frameIndex)
present window
Definition glfwwindow.cc:516
void WindowMakeCurrent(const WindowId id)
make window 'current'
Definition glfwwindow.cc:507
const WindowId EmbedWindow(const Util::Blob &windowData)
embed window in another window
Definition glfwwindow.cc:405
const CoreGraphics::SwapchainId WindowGetSwapchain(const WindowId id)
Get swapchain associated with this window.
Definition glfwwindow.cc:635
void WindowSetTitle(const WindowId id, const Util::String &title)
set title for window
Definition glfwwindow.cc:444
const CoreGraphics::DisplayMode WindowGetDisplayMode(const WindowId id)
get display mode from window
Definition glfwwindow.cc:572
const Util::StringAtom & WindowGetTitle(const WindowId id)
get window title
Definition glfwwindow.cc:617
void DestroyWindow(const WindowId id)
destroy window
Definition glfwwindow.cc:414
const bool WindowIsDecorated(const WindowId id)
get if window is modal
Definition glfwwindow.cc:599
void WindowResize(const WindowId id, SizeT newWidth, SizeT newHeight)
resize window
Definition glfwwindow.cc:434
const Util::StringAtom & WindowGetIcon(const WindowId id)
get window icon
Definition glfwwindow.cc:626
const CoreGraphics::AntiAliasQuality::Code WindowGetAAQuality(const WindowId id)
get display antialias quality
Definition glfwwindow.cc:581
void WindowSetCursorLocked(const WindowId id, bool b)
set if the cursor should be locked to the window
Definition glfwwindow.cc:497
void WindowSetCursorVisible(const WindowId id, bool b)
set if the cursor should be visible
Definition glfwwindow.cc:486
void WindowApplyFullscreen(const WindowId id, Adapter::Code monitor, bool b)
toggle fullscreen
Definition glfwwindow.cc:454
const WindowId CreateWindow(const WindowCreateInfo &info)
create new window
Definition glfwwindow.cc:396
Definition swapchain.h:17
texture type
Definition texture.h:25
Definition window.h:31
CoreGraphics::DisplayMode mode
Definition window.h:32
bool resizable
Definition window.h:36
bool decorated
Definition window.h:37
Util::StringAtom icon
Definition window.h:34
bool vsync
Definition window.h:39
bool fullscreen
Definition window.h:38
Util::StringAtom title
Definition window.h:33
CoreGraphics::AntiAliasQuality::Code aa
Definition window.h:35
Definition window.h:25
A 2-component float vector class.
Definition vec2.h:21
Nebula's universal string class.
Definition string.h:50
int SizeT
Definition types.h:49
int IndexT
Definition types.h:48