rendering improvements
This commit is contained in:
parent
789bb307d5
commit
7f46ac13fa
14 changed files with 296 additions and 179 deletions
|
|
@ -96,7 +96,9 @@ export namespace Crafter {
|
|||
bool mouseRightHeld = false;
|
||||
std::vector<MouseElement*> mouseElements;
|
||||
std::vector<MouseElement*> pendingMouseElements;
|
||||
Rendertarget<std::uint8_t, 4, 4> cursorRenderer;
|
||||
|
||||
Window() = default;
|
||||
Window(std::uint32_t width, std::uint32_t height);
|
||||
Window(std::uint32_t width, std::uint32_t height, const std::string_view title);
|
||||
Window(Window&) = delete;
|
||||
|
|
@ -110,6 +112,9 @@ export namespace Crafter {
|
|||
void Resize(std::uint32_t width, std::uint32_t height);
|
||||
void Render();
|
||||
void Update();
|
||||
void UpdateCursorImage();
|
||||
void SetCusorImage(std::uint16_t sizeX, std::uint16_t sizeY);
|
||||
void SetCusorImageDefault();
|
||||
|
||||
#ifdef CRAFTER_TIMING
|
||||
std::chrono::nanoseconds totalUpdate;
|
||||
|
|
@ -135,6 +140,9 @@ export namespace Crafter {
|
|||
wl_buffer* backBuffer = nullptr;
|
||||
xdg_surface* xdgSurface = nullptr;
|
||||
wl_callback* cb = nullptr;
|
||||
wl_surface* cursorSurface = nullptr;
|
||||
wl_buffer* cursorWlBuffer = nullptr;
|
||||
std::uint32_t cursorBufferOldSize = 0;
|
||||
|
||||
static void xdg_surface_handle_preferred_scale(void* data, wp_fractional_scale_v1*, std::uint32_t scale);
|
||||
static void wl_surface_frame_done(void *data, wl_callback *cb, uint32_t time);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue