XenevaOS
Loading...
Searching...
No Matches
compose3d.h
Go to the documentation of this file.
1
30#ifndef __COMPOSE3D_H__
31#define __COMPOSE3D_H__
32
76#include <stdint.h>
77#include <chitralekha.h>
78#include "window.h"
79
80#define DEODHAI3D_MAX_WINDOWS 128
81#define DEODHAI3D_MAX_REGIONS 64
82
91
98extern bool Deodhai3DLoadPanorama(const char* path);
99
105extern void Deodhai3DSetEnabled(bool enable);
106
110extern void Deodhai3DToggle();
111
115extern bool Deodhai3DEnabled();
116
123extern void XRComposeFrame3D(ChCanvas* canvas);
124
136extern bool Deodhai3DHandleMouse(ChCanvas* canvas, int x, int y, int button);
137
143extern void Deodhai3DSetCamera(float yaw, float pitch);
144
148extern void Deodhai3DGetCamera(float* yaw, float* pitch);
149
158extern bool Deodhai3DWindowSetPosition(Window* win, float x, float y, float z);
159
163extern bool Deodhai3DWindowGetPosition(Window* win, float* x, float* y, float* z);
164
172extern bool Deodhai3DWindowPushDepth(Window* win, float factor);
173
179
185
195extern bool Deodhai3DHandleKey(int key, bool ctrl);
196
202extern bool Deodhai3DScreenToWindow(Window* win, int sx, int sy, int* lx, int* ly);
203
204#endif
float pitch
Definition compose3d.cpp:145
float yaw
Definition compose3d.cpp:144
bool Deodhai3DEnabled()
Deodhai3DEnabled – returns true while 3D mode is active.
Definition compose3d.cpp:1251
void XRComposeFrame3D(ChCanvas *canvas)
XRComposeFrame3D – the 3D compose pipeline; drop-in for XRComposeFrame (falls back to it while 3D mod...
Definition compose3d.cpp:1473
bool Deodhai3DHandleMouse(ChCanvas *canvas, int x, int y, int button)
Deodhai3DHandleMouse – 3D input: drag on empty space turns the camera, drag a titlebar to move a wind...
Definition compose3d.cpp:1620
void Deodhai3DSetCamera(float yaw, float pitch)
Deodhai3DSetCamera – set camera orientation (radians)
Definition compose3d.cpp:1169
bool Deodhai3DWindowSetPosition(Window *win, float x, float y, float z)
Deodhai3DWindowSetPosition – translate a window in 3D space. The window turns to face the camera.
Definition compose3d.cpp:1325
bool Deodhai3DWindowGetPosition(Window *win, float *x, float *y, float *z)
Deodhai3DWindowGetPosition – get the world position of a window.
Definition compose3d.cpp:1346
bool Deodhai3DWindowBringToFront(Window *win)
Deodhai3DWindowBringToFront – eases a window in front of every other window.
Definition compose3d.cpp:1411
bool Deodhai3DScreenToWindow(Window *win, int sx, int sy, int *lx, int *ly)
Deodhai3DScreenToWindow – maps a screen pixel onto a window's own pixel grid using the last composed ...
Definition compose3d.cpp:1454
bool Deodhai3DHandleKey(int key, bool ctrl)
Deodhai3DHandleKey – 3D keyboard shortcuts, all with Ctrl held: Ctrl+3 toggle 3D compositing Ctrl+- p...
Definition compose3d.cpp:1424
void Deodhai3DSetEnabled(bool enable)
Deodhai3DSetEnabled – switch between 3D and the classic 2D compositor. Enabling places every window w...
Definition compose3d.cpp:1273
bool Deodhai3DWindowPushDepth(Window *win, float factor)
Deodhai3DWindowPushDepth – move a window along its view ray (it stays under the same screen spot,...
Definition compose3d.cpp:1372
void Deodhai3DToggle()
Deodhai3DToggle – flips 3D mode.
Definition compose3d.cpp:1304
bool Deodhai3DLoadPanorama(const char *path)
Deodhai3DLoadPanorama – load a 360 degree cylindrical panorama (JPEG). Without one,...
Definition compose3d.cpp:474
bool Deodhai3DWindowSendToBack(Window *win)
Deodhai3DWindowSendToBack – eases a window behind every other window (painter order is by distance,...
Definition compose3d.cpp:1398
void Deodhai3DInitialise(ChCanvas *canvas)
Deodhai3DInitialise – set up the 3D compositor. Call once after the wallpaper is in the back surface ...
Definition compose3d.cpp:1210
void Deodhai3DGetCamera(float *yaw, float *pitch)
Deodhai3DGetCamera – get camera orientation (radians)
Definition compose3d.cpp:1187
ChCanvas * canvas
Definition deomain.cpp:91
ChWindow * win
Definition namdapha.cpp:60
Definition chitralekha.h:40
Definition window.h:78
Definition path.h:8