XenevaOS
Loading...
Searching...
No Matches
Functions | Variables
main.cpp File Reference
#include <stdint.h>
#include <_xeneva.h>
#include <string.h>
#include <stdlib.h>
#include <sys/_keproc.h>
#include <sys/_kefile.h>
#include <chitralekha.h>
#include <sys/_keipcpostbox.h>
#include <sys/mman.h>
#include <font.h>
#include <sys/iocodes.h>
#include <draw.h>
#include "surface.h"
#include "deodxr.h"
#include "dirty.h"
#include "cursor.h"
#include "backdirty.h"
#include "window.h"
#include "clip.h"
#include "_fastcpy.h"
#include "animation.h"
#include "alpha.h"
#include "nanojpg.h"
#include <arm_neon.h>
#include "compose.h"
Include dependency graph for main.cpp:

Functions

uint32_t DeodhaiAllocateNewHandle ()
 DeodhaiAllocateNewHandle – get a new window handle.
 
void DeodhaiInitialiseData ()
 DeodhaiInitialiseData – initialise all data.
 
void DeodhaiAddWindow (Window *win)
 DeodhaiAddWindow – add a window to window list.
 
void DeodhaiRemoveWindow (Window *win)
 
void DeodhaiAddWindowAlwaysOnTop (Window *win)
 DeodhaiAddWindow – add a window to window list.
 
void DeodhaiRemoveWindowAlwaysOnTop (Window *win)
 
WindowDeodhaiCreateWindow (int x, int y, int w, int h, uint16_t flags, uint16_t ownerId, char *title)
 DeodhaiCreateWindow – create a new deodhai window.
 
void CursorStoreBack (ChCanvas *canv, Cursor *cur, unsigned x, unsigned y)
 
void CursorDrawBack (ChCanvas *canv, Cursor *cur, unsigned x, unsigned y)
 
void DrawWallpaper (ChCanvas *canv, char *filename)
 DrawWallpaper for getting jpeg image as wallpaper fully jpeg encoder is needed, i use synfig studio for jpeg encoder.
 
void XRComposeFrame (ChCanvas *canvas)
 
void DeodhaiWindowMakeTop (Window *win)
 DeodhaiWindowMakeTop – brings a window to front.
 
void DeodhaiWindowSetFocused (Window *win, bool notify)
 DeodhaiWindowSetFocused – cast focus to a new window.
 
void DeodhaiWindowMove (Window *win, int x, int y)
 DeodhaiWindowMove – move an window to a new location.
 
bool DeodhaiCheckWindowPointOcclusion (Window *win, int x, int y)
 DeodhaiCheckWindowPointOcclusion – checks if given x and y of point of a window is occluded by another window , from given window to front window of the list.
 
void DeodhaiWindowCheckDraggable (int x, int y, int button)
 DeodhaiWindowCheckDraggable – check for draggable windows.
 
void DeodhaiSendMouseEvent (int handle, int ownerId, uint8_t handleType, uint8_t eventType, int x, int y, int button)
 DeodhaiSendMouseEvent – send mouse event to desired window.
 
void DeodhaiBroadcastMouse (int mouse_x, int mouse_y, int button)
 
void DeodhaiWindowHide (Window *win)
 DeodhaiWindowHide – hides a window.
 
void DeodhaiBroadcastKey (int code)
 
void DeodhaiBroadcastMessage (PostEvent *e, Window *skippablewin)
 DeodhaiBrodcastMessage – broadcast a message to every window.
 
int main (int argc, char *argv[])
 main – main entry
 
void DeodhaiUpdateBits (bool window_update, bool skip_disable)
 
int _get_gpu_display_id ()
 
bool _is_gpu_enabled ()
 
int _get_gpu_fd ()
 
Window_get_always_on_top ()
 

Variables

ChFontf2
 DeodhaiXR – The Graphics compositing pipeline Supports three types of input – (1) Mouse (2) Keyboard (3) Special XR input two types of rendering : 2D Compositing for non-xr system(GPU/Software), 3D compositing for XR system (GPU)
 
ChRect rectb
 
int x_
 
int y_
 

Function Documentation

◆ _get_always_on_top()

Window * _get_always_on_top ( )

◆ _get_gpu_display_id()

int _get_gpu_display_id ( )

◆ _get_gpu_fd()

int _get_gpu_fd ( )

◆ _is_gpu_enabled()

bool _is_gpu_enabled ( )

◆ CursorDrawBack()

void CursorDrawBack ( ChCanvas canv,
Cursor cur,
unsigned  x,
unsigned  y 
)

◆ CursorStoreBack()

void CursorStoreBack ( ChCanvas canv,
Cursor cur,
unsigned  x,
unsigned  y 
)

◆ DeodhaiAddWindow()

void DeodhaiAddWindow ( Window win)

DeodhaiAddWindow – add a window to window list.

Parameters
win– Pointer to window

◆ DeodhaiAddWindowAlwaysOnTop()

void DeodhaiAddWindowAlwaysOnTop ( Window win)

DeodhaiAddWindow – add a window to window list.

Parameters
win– Pointer to window

◆ DeodhaiAllocateNewHandle()

uint32_t DeodhaiAllocateNewHandle ( )

DeodhaiAllocateNewHandle – get a new window handle.

◆ DeodhaiBroadcastKey()

void DeodhaiBroadcastKey ( int  code)

◆ DeodhaiBroadcastMessage()

void DeodhaiBroadcastMessage ( PostEvent e,
Window skippablewin 
)

DeodhaiBrodcastMessage – broadcast a message to every window.

Parameters
e– PostEvent to broadcast

◆ DeodhaiBroadcastMouse()

void DeodhaiBroadcastMouse ( int  mouse_x,
int  mouse_y,
int  button 
)

◆ DeodhaiCheckWindowPointOcclusion()

bool DeodhaiCheckWindowPointOcclusion ( Window win,
int  x,
int  y 
)

DeodhaiCheckWindowPointOcclusion – checks if given x and y of point of a window is occluded by another window , from given window to front window of the list.

Parameters
win– Pointer to window to use for point check
x– x coord of the point
y– y coord of the point

◆ DeodhaiCreateWindow()

Window * DeodhaiCreateWindow ( int  x,
int  y,
int  w,
int  h,
uint16_t  flags,
uint16_t  ownerId,
char *  title 
)

DeodhaiCreateWindow – create a new deodhai window.

◆ DeodhaiInitialiseData()

void DeodhaiInitialiseData ( )

DeodhaiInitialiseData – initialise all data.

◆ DeodhaiRemoveWindow()

void DeodhaiRemoveWindow ( Window win)

◆ DeodhaiRemoveWindowAlwaysOnTop()

void DeodhaiRemoveWindowAlwaysOnTop ( Window win)

◆ DeodhaiSendMouseEvent()

void DeodhaiSendMouseEvent ( int  handle,
int  ownerId,
uint8_t  handleType,
uint8_t  eventType,
int  x,
int  y,
int  button 
)

DeodhaiSendMouseEvent – send mouse event to desired window.

Parameters
win– Pointer to window
eventType– either MOUSE_EVENT or MOUSE_LEAVE
x– Mouse x location
y– Mouse y location
button– Mouse button state

◆ DeodhaiUpdateBits()

void DeodhaiUpdateBits ( bool  window_update,
bool  skip_disable 
)

◆ DeodhaiWindowCheckDraggable()

void DeodhaiWindowCheckDraggable ( int  x,
int  y,
int  button 
)

DeodhaiWindowCheckDraggable – check for draggable windows.

Parameters
x– mouse x pos
y– mouse y pos
button– mouse button state

◆ DeodhaiWindowHide()

void DeodhaiWindowHide ( Window win)

DeodhaiWindowHide – hides a window.

Parameters
win– Pointer to window to hide

◆ DeodhaiWindowMakeTop()

void DeodhaiWindowMakeTop ( Window win)

DeodhaiWindowMakeTop – brings a window to front.

Parameters
win– window to brin front

◆ DeodhaiWindowMove()

void DeodhaiWindowMove ( Window win,
int  x,
int  y 
)

DeodhaiWindowMove – move an window to a new location.

Parameters
win– Pointer to window
x– new x position
y– new y position

◆ DeodhaiWindowSetFocused()

void DeodhaiWindowSetFocused ( Window win,
bool  notify 
)

DeodhaiWindowSetFocused – cast focus to a new window.

◆ DrawWallpaper()

void DrawWallpaper ( ChCanvas canv,
char *  filename 
)

DrawWallpaper for getting jpeg image as wallpaper fully jpeg encoder is needed, i use synfig studio for jpeg encoder.

◆ main()

int main ( int  argc,
char *  argv[] 
)

main – main entry

◆ XRComposeFrame()

void XRComposeFrame ( ChCanvas canvas)

Normal application windows

do either one – dirty area tracking or else update all

Always on Top window , stacking order

Variable Documentation

◆ f2

ChFont* f2

DeodhaiXR – The Graphics compositing pipeline Supports three types of input – (1) Mouse (2) Keyboard (3) Special XR input two types of rendering : 2D Compositing for non-xr system(GPU/Software), 3D compositing for XR system (GPU)

◆ rectb

ChRect rectb

◆ x_

int x_

◆ y_

int y_