parent
72fb4bcb67
commit
ec23bf6a0f
|
@ -171,8 +171,8 @@ MainWndProc(HWND hwnd,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_direct3d_args(int argc, char **argv)
|
engine_direct3d_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
WNDCLASS wc;
|
WNDCLASS wc;
|
||||||
RECT rect;
|
RECT rect;
|
||||||
|
@ -182,20 +182,9 @@ engine_direct3d_args(int argc, char **argv)
|
||||||
DWORD style;
|
DWORD style;
|
||||||
int depth;
|
int depth;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "direct3d")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
instance = GetModuleHandle(NULL);
|
instance = GetModuleHandle(NULL);
|
||||||
if (!instance) return 0;
|
if (!instance) return EINA_FALSE;
|
||||||
|
|
||||||
wc.style = 0;
|
wc.style = 0;
|
||||||
wc.lpfnWndProc = MainWndProc;
|
wc.lpfnWndProc = MainWndProc;
|
||||||
|
@ -213,8 +202,8 @@ engine_direct3d_args(int argc, char **argv)
|
||||||
|
|
||||||
rect.left = 0;
|
rect.left = 0;
|
||||||
rect.top = 0;
|
rect.top = 0;
|
||||||
rect.right = win_w;
|
rect.right = width;
|
||||||
rect.bottom = win_h;
|
rect.bottom = height;
|
||||||
AdjustWindowRect (&rect, WS_OVERLAPPEDWINDOW | WS_SIZEBOX, FALSE);
|
AdjustWindowRect (&rect, WS_OVERLAPPEDWINDOW | WS_SIZEBOX, FALSE);
|
||||||
|
|
||||||
window = CreateWindowEx(0,
|
window = CreateWindowEx(0,
|
||||||
|
@ -261,7 +250,7 @@ engine_direct3d_args(int argc, char **argv)
|
||||||
ShowWindow(window, SW_SHOWDEFAULT);
|
ShowWindow(window, SW_SHOWDEFAULT);
|
||||||
UpdateWindow(window);
|
UpdateWindow(window);
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
DestroyWindow(window);
|
DestroyWindow(window);
|
||||||
|
@ -270,7 +259,7 @@ engine_direct3d_args(int argc, char **argv)
|
||||||
free_library:
|
free_library:
|
||||||
FreeLibrary(instance);
|
FreeLibrary(instance);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -7,7 +7,7 @@ extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
int engine_direct3d_args(int argc, char **argv);
|
Eina_Bool engine_direct3d_args(const char *engine, int width, int height);
|
||||||
void engine_direct3d_loop(void);
|
void engine_direct3d_loop(void);
|
||||||
void engine_direct3d_shutdown(void);
|
void engine_direct3d_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -22,30 +22,19 @@ static IDirectFBSurface *_dfb_surface;
|
||||||
} \
|
} \
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_directfb_args(int argc, char **argv)
|
engine_directfb_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
Evas_Engine_Info_DirectFB *einfo;
|
Evas_Engine_Info_DirectFB *einfo;
|
||||||
DFBWindowDescription desc;
|
DFBWindowDescription desc;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "directfb")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("directfb"));
|
evas_output_method_set(evas, evas_render_method_lookup("directfb"));
|
||||||
einfo = (Evas_Engine_Info_DirectFB *)evas_engine_info_get(evas);
|
einfo = (Evas_Engine_Info_DirectFB *)evas_engine_info_get(evas);
|
||||||
if (!einfo)
|
if (!einfo)
|
||||||
{
|
{
|
||||||
printf("Evas does not support the DirectFB Engine\n");
|
printf("Evas does not support the DirectFB Engine\n");
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
DFBCHECK(DirectFBInit(NULL, NULL));
|
DFBCHECK(DirectFBInit(NULL, NULL));
|
||||||
|
@ -58,8 +47,8 @@ engine_directfb_args(int argc, char **argv)
|
||||||
desc.flags = (DWDESC_POSX | DWDESC_POSY | DWDESC_WIDTH | DWDESC_HEIGHT | DWDESC_PIXELFORMAT);
|
desc.flags = (DWDESC_POSX | DWDESC_POSY | DWDESC_WIDTH | DWDESC_HEIGHT | DWDESC_PIXELFORMAT);
|
||||||
desc.posx = 0;
|
desc.posx = 0;
|
||||||
desc.posy = 0;
|
desc.posy = 0;
|
||||||
desc.width = win_w;
|
desc.width = width;
|
||||||
desc.height = win_h;
|
desc.height = height;
|
||||||
desc.pixelformat = DSPF_ARGB;
|
desc.pixelformat = DSPF_ARGB;
|
||||||
|
|
||||||
DFBCHECK(_layer->CreateWindow(_layer, &desc, &_dfb_window));
|
DFBCHECK(_layer->CreateWindow(_layer, &desc, &_dfb_window));
|
||||||
|
@ -74,10 +63,10 @@ engine_directfb_args(int argc, char **argv)
|
||||||
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
||||||
{
|
{
|
||||||
printf("Evas can not setup the informations of the DirectFB Engine\n");
|
printf("Evas can not setup the informations of the DirectFB Engine\n");
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_DIRECTFB_H
|
#ifndef ENGINE_DIRECTFB_H
|
||||||
#define ENGINE_DIRECTFB_H
|
#define ENGINE_DIRECTFB_H
|
||||||
|
|
||||||
int engine_directfb_args(int argc, char **argv);
|
Eina_Bool engine_directfb_args(const char *engine, int width, int height);
|
||||||
void engine_directfb_loop(void);
|
void engine_directfb_loop(void);
|
||||||
void engine_directfb_shutdown(void);
|
void engine_directfb_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -2,29 +2,18 @@
|
||||||
|
|
||||||
#include <Evas_Engine_FB.h>
|
#include <Evas_Engine_FB.h>
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_fb_args(int argc, char **argv)
|
engine_fb_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
Evas_Engine_Info_FB *einfo;
|
Evas_Engine_Info_FB *einfo;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "fb")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("fb"));
|
evas_output_method_set(evas, evas_render_method_lookup("fb"));
|
||||||
einfo = (Evas_Engine_Info_FB *)evas_engine_info_get(evas);
|
einfo = (Evas_Engine_Info_FB *)evas_engine_info_get(evas);
|
||||||
if (!einfo)
|
if (!einfo)
|
||||||
{
|
{
|
||||||
printf("Evas does not support the FB Engine\n");
|
printf("Evas does not support the FB Engine\n");
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
einfo->info.virtual_terminal = 0;
|
einfo->info.virtual_terminal = 0;
|
||||||
|
@ -35,10 +24,10 @@ engine_fb_args(int argc, char **argv)
|
||||||
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
||||||
{
|
{
|
||||||
printf("Evas can not setup the informations of the FB Engine\n");
|
printf("Evas can not setup the informations of the FB Engine\n");
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_FB_H
|
#ifndef ENGINE_FB_H
|
||||||
#define ENGINE_FB_H
|
#define ENGINE_FB_H
|
||||||
|
|
||||||
int engine_fb_args(int argc, char **argv);
|
Eina_Bool engine_fb_args(const char *engine, int width, int height);
|
||||||
void engine_fb_loop(void);
|
void engine_fb_loop(void);
|
||||||
void engine_fb_shutdown(void);
|
void engine_fb_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -172,8 +172,8 @@ MainWndProc(HWND hwnd,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_gl_glew_args(int argc, char **argv)
|
engine_gl_glew_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
WNDCLASS wc;
|
WNDCLASS wc;
|
||||||
RECT rect;
|
RECT rect;
|
||||||
|
@ -182,20 +182,9 @@ engine_gl_glew_args(int argc, char **argv)
|
||||||
DWORD style;
|
DWORD style;
|
||||||
int depth;
|
int depth;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "gl-glew")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
instance = GetModuleHandle(NULL);
|
instance = GetModuleHandle(NULL);
|
||||||
if (!instance) return 0;
|
if (!instance) return EINA_FALSE;
|
||||||
|
|
||||||
wc.style = 0;
|
wc.style = 0;
|
||||||
wc.lpfnWndProc = MainWndProc;
|
wc.lpfnWndProc = MainWndProc;
|
||||||
|
@ -213,8 +202,8 @@ engine_gl_glew_args(int argc, char **argv)
|
||||||
|
|
||||||
rect.left = 0;
|
rect.left = 0;
|
||||||
rect.top = 0;
|
rect.top = 0;
|
||||||
rect.right = win_w;
|
rect.right = width;
|
||||||
rect.bottom = win_h;
|
rect.bottom = height;
|
||||||
AdjustWindowRect (&rect, WS_CLIPCHILDREN | WS_CLIPSIBLINGS | WS_OVERLAPPEDWINDOW | WS_SIZEBOX, FALSE);
|
AdjustWindowRect (&rect, WS_CLIPCHILDREN | WS_CLIPSIBLINGS | WS_OVERLAPPEDWINDOW | WS_SIZEBOX, FALSE);
|
||||||
|
|
||||||
window = CreateWindowEx(0,
|
window = CreateWindowEx(0,
|
||||||
|
@ -260,7 +249,7 @@ engine_gl_glew_args(int argc, char **argv)
|
||||||
ShowWindow(window, SW_SHOWDEFAULT);
|
ShowWindow(window, SW_SHOWDEFAULT);
|
||||||
UpdateWindow(window);
|
UpdateWindow(window);
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
DestroyWindow(window);
|
DestroyWindow(window);
|
||||||
|
@ -269,7 +258,7 @@ engine_gl_glew_args(int argc, char **argv)
|
||||||
free_library:
|
free_library:
|
||||||
FreeLibrary(instance);
|
FreeLibrary(instance);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
#define __ENGINE_GL_GLEW_H__
|
#define __ENGINE_GL_GLEW_H__
|
||||||
|
|
||||||
|
|
||||||
int engine_gl_glew_args(int argc, char **argv);
|
Eina_Bool engine_gl_glew_args(const char *engine, int width, int height);
|
||||||
void engine_gl_glew_loop(void);
|
void engine_gl_glew_loop(void);
|
||||||
void engine_gl_glew_shutdown(void);
|
void engine_gl_glew_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -3,24 +3,12 @@
|
||||||
|
|
||||||
#include <Evas_Engine_GL_SDL.h>
|
#include <Evas_Engine_GL_SDL.h>
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_gl_sdl_args(int argc, char **argv)
|
engine_gl_sdl_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
Evas_Engine_Info_GL_SDL *einfo;
|
Evas_Engine_Info_GL_SDL *einfo;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; ++i)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e") && (i < (argc - 1))))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "gl-sdl")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
if (ok == 1)
|
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("gl_sdl"));
|
evas_output_method_set(evas, evas_render_method_lookup("gl_sdl"));
|
||||||
|
|
||||||
einfo = (Evas_Engine_Info_GL_SDL *) evas_engine_info_get(evas);
|
einfo = (Evas_Engine_Info_GL_SDL *) evas_engine_info_get(evas);
|
||||||
|
@ -32,10 +20,10 @@ engine_gl_sdl_args(int argc, char **argv)
|
||||||
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
||||||
{
|
{
|
||||||
printf("Evas could not initialize the GL SDL Engine\n");
|
printf("Evas could not initialize the GL SDL Engine\n");
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_GL_SDL_H
|
#ifndef ENGINE_GL_SDL_H
|
||||||
#define ENGINE_GL_SDL_H
|
#define ENGINE_GL_SDL_H
|
||||||
|
|
||||||
int engine_gl_sdl_args(int argc, char **argv);
|
Eina_Bool engine_gl_sdl_args(const char *engine, int width, int height);
|
||||||
void engine_gl_sdl_loop(void);
|
void engine_gl_sdl_loop(void);
|
||||||
void engine_gl_sdl_shutdown(void);
|
void engine_gl_sdl_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -8,28 +8,17 @@ static Display *disp = NULL;
|
||||||
static Window win = 0;
|
static Window win = 0;
|
||||||
static int first_expose = 0;
|
static int first_expose = 0;
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_gl_x11_args(int argc, char **argv)
|
engine_gl_x11_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
XSetWindowAttributes attr;
|
XSetWindowAttributes attr;
|
||||||
XClassHint chint;
|
XClassHint chint;
|
||||||
XSizeHints szhints;
|
XSizeHints szhints;
|
||||||
Evas_Engine_Info_GL_X11 *einfo;
|
Evas_Engine_Info_GL_X11 *einfo;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "gl")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
disp = XOpenDisplay(NULL);
|
disp = XOpenDisplay(NULL);
|
||||||
if (!disp) return 0;
|
if (!disp) return EINA_FALSE;
|
||||||
|
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("gl_x11"));
|
evas_output_method_set(evas, evas_render_method_lookup("gl_x11"));
|
||||||
einfo = (Evas_Engine_Info_GL_X11 *)evas_engine_info_get(evas);
|
einfo = (Evas_Engine_Info_GL_X11 *)evas_engine_info_get(evas);
|
||||||
|
@ -54,7 +43,7 @@ engine_gl_x11_args(int argc, char **argv)
|
||||||
KeyPressMask | KeyReleaseMask;
|
KeyPressMask | KeyReleaseMask;
|
||||||
attr.bit_gravity = ForgetGravity;
|
attr.bit_gravity = ForgetGravity;
|
||||||
win = XCreateWindow(disp, DefaultRootWindow(disp),
|
win = XCreateWindow(disp, DefaultRootWindow(disp),
|
||||||
0, 0, win_w, win_h, 0,
|
0, 0, width, height, 0,
|
||||||
einfo->info.depth, InputOutput,
|
einfo->info.depth, InputOutput,
|
||||||
einfo->info.visual,
|
einfo->info.visual,
|
||||||
CWBackingStore | CWColormap |
|
CWBackingStore | CWColormap |
|
||||||
|
@ -76,21 +65,21 @@ engine_gl_x11_args(int argc, char **argv)
|
||||||
chint.res_class = "Expedite";
|
chint.res_class = "Expedite";
|
||||||
XSetClassHint(disp, win, &chint);
|
XSetClassHint(disp, win, &chint);
|
||||||
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
|
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
|
||||||
szhints.min_width = szhints.max_width = win_w;
|
szhints.min_width = szhints.max_width = width;
|
||||||
szhints.min_height = szhints.max_height = win_h;
|
szhints.min_height = szhints.max_height = height;
|
||||||
XSetWMNormalHints(disp, win, &szhints);
|
XSetWMNormalHints(disp, win, &szhints);
|
||||||
XMapWindow(disp, win);
|
XMapWindow(disp, win);
|
||||||
XSync(disp, False);
|
XSync(disp, False);
|
||||||
while (!first_expose)
|
while (!first_expose)
|
||||||
engine_gl_x11_loop();
|
engine_gl_x11_loop();
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
XDestroyWindow(disp, win);
|
XDestroyWindow(disp, win);
|
||||||
close_display:
|
close_display:
|
||||||
XCloseDisplay(disp);
|
XCloseDisplay(disp);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_GL_X11_H
|
#ifndef ENGINE_GL_X11_H
|
||||||
#define ENGINE_GL_X11_H
|
#define ENGINE_GL_X11_H
|
||||||
|
|
||||||
int engine_gl_x11_args(int argc, char **argv);
|
Eina_Bool engine_gl_x11_args(const char *engine, int width, int height);
|
||||||
void engine_gl_x11_loop(void);
|
void engine_gl_x11_loop(void);
|
||||||
void engine_gl_x11_shutdown(void);
|
void engine_gl_x11_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_QUARTZ_H
|
#ifndef ENGINE_QUARTZ_H
|
||||||
#define ENGINE_QUARTZ_H
|
#define ENGINE_QUARTZ_H
|
||||||
|
|
||||||
int engine_quartz_args(int argc, char **argv);
|
Eina_Bool engine_quartz_args(const char *engine, int width, int height);
|
||||||
void engine_quartz_loop(void);
|
void engine_quartz_loop(void);
|
||||||
void engine_quartz_shutdown(void);
|
void engine_quartz_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -46,29 +46,18 @@ static NSWindow * main_window;
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_quartz_args(int argc, char **argv)
|
engine_quartz_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
Evas_Engine_Info_Quartz *einfo;
|
Evas_Engine_Info_Quartz *einfo;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "quartz")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("quartz"));
|
evas_output_method_set(evas, evas_render_method_lookup("quartz"));
|
||||||
einfo = (Evas_Engine_Info_Quartz *)evas_engine_info_get(evas);
|
einfo = (Evas_Engine_Info_Quartz *)evas_engine_info_get(evas);
|
||||||
if (!einfo)
|
if (!einfo)
|
||||||
{
|
{
|
||||||
printf("Evas does not support the Quartz Engine\n");
|
printf("Evas does not support the Quartz Engine\n");
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Set up the Cocoa runtime
|
// Set up the Cocoa runtime
|
||||||
|
@ -83,30 +72,30 @@ engine_quartz_args(int argc, char **argv)
|
||||||
[NSApp finishLaunching];
|
[NSApp finishLaunching];
|
||||||
|
|
||||||
// Create our main window, and embed an EvasView in it
|
// Create our main window, and embed an EvasView in it
|
||||||
main_window = [[NSWindow alloc] initWithContentRect:NSMakeRect(20,500,win_w,win_h) styleMask:(NSTitledWindowMask | NSClosableWindowMask | NSResizableWindowMask | NSMiniaturizableWindowMask) backing:NSBackingStoreBuffered defer:NO screen:nil];
|
main_window = [[NSWindow alloc] initWithContentRect:NSMakeRect(20,500,width,height) styleMask:(NSTitledWindowMask | NSClosableWindowMask | NSResizableWindowMask | NSMiniaturizableWindowMask) backing:NSBackingStoreBuffered defer:NO screen:nil];
|
||||||
[main_window makeKeyAndOrderFront:NSApp];
|
[main_window makeKeyAndOrderFront:NSApp];
|
||||||
[main_window setTitle:@"Expedite"];
|
[main_window setTitle:@"Expedite"];
|
||||||
[main_window makeMainWindow];
|
[main_window makeMainWindow];
|
||||||
[main_window setAcceptsMouseMovedEvents:YES];
|
[main_window setAcceptsMouseMovedEvents:YES];
|
||||||
[NSApp activateIgnoringOtherApps:YES];
|
[NSApp activateIgnoringOtherApps:YES];
|
||||||
|
|
||||||
evas_view = [[EvasView alloc] initWithFrame:NSMakeRect(0,0,win_w,win_h)];
|
evas_view = [[EvasView alloc] initWithFrame:NSMakeRect(0,0,width,height)];
|
||||||
[[main_window contentView] addSubview:evas_view];
|
[[main_window contentView] addSubview:evas_view];
|
||||||
|
|
||||||
// drawRect: must be run at least once, to make sure we've set ctx
|
// drawRect: must be run at least once, to make sure we've set ctx
|
||||||
[evas_view display];
|
[evas_view display];
|
||||||
|
|
||||||
evas_output_size_set(evas, win_w, win_h);
|
evas_output_size_set(evas, width, height);
|
||||||
evas_output_viewport_set(evas, 0, 0, win_w, win_h);
|
evas_output_viewport_set(evas, 0, 0, width, height);
|
||||||
|
|
||||||
einfo->info.context = [evas_view context];
|
einfo->info.context = [evas_view context];
|
||||||
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
||||||
{
|
{
|
||||||
printf("Evas can not setup the informations of the Quartz Engine\n");
|
printf("Evas can not setup the informations of the Quartz Engine\n");
|
||||||
exit(-1);
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -263,8 +263,8 @@ MainWndProc(HWND hwnd,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_software_16_ddraw_args(int argc, char **argv)
|
engine_software_16_ddraw_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
WNDCLASS wc;
|
WNDCLASS wc;
|
||||||
RECT rect;
|
RECT rect;
|
||||||
|
@ -277,20 +277,9 @@ engine_software_16_ddraw_args(int argc, char **argv)
|
||||||
DWORD exstyle;
|
DWORD exstyle;
|
||||||
int depth;
|
int depth;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "ddraw-16")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
instance = GetModuleHandle(NULL);
|
instance = GetModuleHandle(NULL);
|
||||||
if (!instance) return 0;
|
if (!instance) return EINA_FALSE;
|
||||||
|
|
||||||
wc.style = CS_HREDRAW | CS_VREDRAW;
|
wc.style = CS_HREDRAW | CS_VREDRAW;
|
||||||
wc.lpfnWndProc = MainWndProc;
|
wc.lpfnWndProc = MainWndProc;
|
||||||
|
@ -311,8 +300,8 @@ engine_software_16_ddraw_args(int argc, char **argv)
|
||||||
|
|
||||||
rect.left = 0;
|
rect.left = 0;
|
||||||
rect.top = 0;
|
rect.top = 0;
|
||||||
rect.right = win_w;
|
rect.right = width;
|
||||||
rect.bottom = win_h;
|
rect.bottom = height;
|
||||||
AdjustWindowRectEx(&rect, style, FALSE, exstyle);
|
AdjustWindowRectEx(&rect, style, FALSE, exstyle);
|
||||||
|
|
||||||
window = CreateWindowEx(exstyle,
|
window = CreateWindowEx(exstyle,
|
||||||
|
@ -331,7 +320,7 @@ engine_software_16_ddraw_args(int argc, char **argv)
|
||||||
if (!SetWindowLong(window, GWL_STYLE, style))
|
if (!SetWindowLong(window, GWL_STYLE, style))
|
||||||
goto unregister_class;
|
goto unregister_class;
|
||||||
|
|
||||||
if (!_directdraw_init(window, win_w, win_h,
|
if (!_directdraw_init(window, width, height,
|
||||||
&object,
|
&object,
|
||||||
&surface_primary,
|
&surface_primary,
|
||||||
&surface_back,
|
&surface_back,
|
||||||
|
@ -365,7 +354,7 @@ engine_software_16_ddraw_args(int argc, char **argv)
|
||||||
ShowWindow(window, SW_SHOWDEFAULT);
|
ShowWindow(window, SW_SHOWDEFAULT);
|
||||||
UpdateWindow(window);
|
UpdateWindow(window);
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
DestroyWindow(window);
|
DestroyWindow(window);
|
||||||
|
@ -374,7 +363,7 @@ engine_software_16_ddraw_args(int argc, char **argv)
|
||||||
free_library:
|
free_library:
|
||||||
FreeLibrary(instance);
|
FreeLibrary(instance);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -7,7 +7,7 @@ extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
int engine_software_16_ddraw_args(int argc, char **argv);
|
Eina_Bool engine_software_16_ddraw_args(const char *engine, int width, int height);
|
||||||
void engine_software_16_ddraw_loop(void);
|
void engine_software_16_ddraw_loop(void);
|
||||||
void engine_software_16_ddraw_shutdown(void);
|
void engine_software_16_ddraw_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -166,8 +166,8 @@ MainWndProc(HWND hwnd,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_software_16_wince_args(int argc, char **argv)
|
engine_software_16_wince_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
WNDCLASS wc;
|
WNDCLASS wc;
|
||||||
RECT rect;
|
RECT rect;
|
||||||
|
@ -185,22 +185,15 @@ engine_software_16_wince_args(int argc, char **argv)
|
||||||
int ok = 0;
|
int ok = 0;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
if (!strcmp(engine, "wince")) ok = 1;
|
||||||
{
|
if (!strcmp(engine, "wince-fb")) { ok = 1; backend = 1; }
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
if (!strcmp(engine, "wince-gapi")) { ok = 1; backend = 2; }
|
||||||
{
|
if (!strcmp(engine, "wince-ddraw")) { ok = 1; backend = 3; }
|
||||||
i++;
|
if (!strcmp(engine, "wince-gdi")) { ok = 1; backend = 4; }
|
||||||
if (!strcmp(argv[i], "wince")) ok = 1;
|
if (!ok) return EINA_FALSE;
|
||||||
if (!strcmp(argv[i], "wince-fb")) { ok = 1; backend = 1; }
|
|
||||||
if (!strcmp(argv[i], "wince-gapi")) { ok = 1; backend = 2; }
|
|
||||||
if (!strcmp(argv[i], "wince-ddraw")) { ok = 1; backend = 3; }
|
|
||||||
if (!strcmp(argv[i], "wince-gdi")) { ok = 1; backend = 4; }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
instance = GetModuleHandle(NULL);
|
instance = GetModuleHandle(NULL);
|
||||||
if (!instance) return 0;
|
if (!instance) return EINA_FALSE;
|
||||||
|
|
||||||
memset (&wc, 0, sizeof (wc));
|
memset (&wc, 0, sizeof (wc));
|
||||||
wc.style = CS_HREDRAW | CS_VREDRAW;
|
wc.style = CS_HREDRAW | CS_VREDRAW;
|
||||||
|
@ -256,8 +249,8 @@ engine_software_16_wince_args(int argc, char **argv)
|
||||||
}
|
}
|
||||||
|
|
||||||
einfo->info.window = window;
|
einfo->info.window = window;
|
||||||
einfo->info.width = win_w;
|
einfo->info.width = width;
|
||||||
einfo->info.height = win_h;
|
einfo->info.height = height;
|
||||||
einfo->info.backend = backend;
|
einfo->info.backend = backend;
|
||||||
einfo->info.rotation = 0;
|
einfo->info.rotation = 0;
|
||||||
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
||||||
|
@ -273,7 +266,7 @@ engine_software_16_wince_args(int argc, char **argv)
|
||||||
ShowWindow(window, SW_SHOWDEFAULT);
|
ShowWindow(window, SW_SHOWDEFAULT);
|
||||||
UpdateWindow(window);
|
UpdateWindow(window);
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
DestroyWindow(window);
|
DestroyWindow(window);
|
||||||
|
@ -288,7 +281,7 @@ engine_software_16_wince_args(int argc, char **argv)
|
||||||
free_library:
|
free_library:
|
||||||
FreeLibrary(instance);
|
FreeLibrary(instance);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
#define __ENGINE_SOFTWARE_16_WINCE_H__
|
#define __ENGINE_SOFTWARE_16_WINCE_H__
|
||||||
|
|
||||||
|
|
||||||
int engine_software_16_wince_args(int argc, char **argv);
|
Eina_Bool engine_software_16_wince_args(const char *engine, int width, int height);
|
||||||
void engine_software_16_wince_loop(void);
|
void engine_software_16_wince_loop(void);
|
||||||
void engine_software_16_wince_shutdown(void);
|
void engine_software_16_wince_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -8,28 +8,17 @@ static Display *disp = NULL;
|
||||||
static Window win = 0;
|
static Window win = 0;
|
||||||
static int first_expose = 0;
|
static int first_expose = 0;
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_software_16_x11_args(int argc, char **argv)
|
engine_software_16_x11_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
XSetWindowAttributes attr;
|
XSetWindowAttributes attr;
|
||||||
XClassHint chint;
|
XClassHint chint;
|
||||||
XSizeHints szhints;
|
XSizeHints szhints;
|
||||||
Evas_Engine_Info_Software_16_X11 *einfo;
|
Evas_Engine_Info_Software_16_X11 *einfo;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "x11-16")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
disp = XOpenDisplay(NULL);
|
disp = XOpenDisplay(NULL);
|
||||||
if (!disp) return 0;
|
if (!disp) return EINA_FALSE;
|
||||||
|
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("software_16_x11"));
|
evas_output_method_set(evas, evas_render_method_lookup("software_16_x11"));
|
||||||
einfo = (Evas_Engine_Info_Software_16_X11 *)evas_engine_info_get(evas);
|
einfo = (Evas_Engine_Info_Software_16_X11 *)evas_engine_info_get(evas);
|
||||||
|
@ -50,7 +39,7 @@ engine_software_16_x11_args(int argc, char **argv)
|
||||||
KeyPressMask | KeyReleaseMask;
|
KeyPressMask | KeyReleaseMask;
|
||||||
attr.bit_gravity = ForgetGravity;
|
attr.bit_gravity = ForgetGravity;
|
||||||
win = XCreateWindow(disp, DefaultRootWindow(disp),
|
win = XCreateWindow(disp, DefaultRootWindow(disp),
|
||||||
0, 0, win_w, win_h, 0,
|
0, 0, width, height, 0,
|
||||||
DefaultDepth(disp, DefaultScreen(disp)), InputOutput,
|
DefaultDepth(disp, DefaultScreen(disp)), InputOutput,
|
||||||
DefaultVisual(disp, DefaultScreen(disp)),
|
DefaultVisual(disp, DefaultScreen(disp)),
|
||||||
CWBackingStore | CWColormap |
|
CWBackingStore | CWColormap |
|
||||||
|
@ -72,21 +61,21 @@ engine_software_16_x11_args(int argc, char **argv)
|
||||||
chint.res_class = "Expedite";
|
chint.res_class = "Expedite";
|
||||||
XSetClassHint(disp, win, &chint);
|
XSetClassHint(disp, win, &chint);
|
||||||
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
|
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
|
||||||
szhints.min_width = szhints.max_width = win_w;
|
szhints.min_width = szhints.max_width = width;
|
||||||
szhints.min_height = szhints.max_height = win_h;
|
szhints.min_height = szhints.max_height = height;
|
||||||
XSetWMNormalHints(disp, win, &szhints);
|
XSetWMNormalHints(disp, win, &szhints);
|
||||||
XMapWindow(disp, win);
|
XMapWindow(disp, win);
|
||||||
XSync(disp, False);
|
XSync(disp, False);
|
||||||
while (!first_expose)
|
while (!first_expose)
|
||||||
engine_software_16_x11_loop();
|
engine_software_16_x11_loop();
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
XDestroyWindow(disp, win);
|
XDestroyWindow(disp, win);
|
||||||
close_display:
|
close_display:
|
||||||
XCloseDisplay(disp);
|
XCloseDisplay(disp);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_SOFTWARE_16_X11_H
|
#ifndef ENGINE_SOFTWARE_16_X11_H
|
||||||
#define ENGINE_SOFTWARE_16_X11_H
|
#define ENGINE_SOFTWARE_16_X11_H
|
||||||
|
|
||||||
int engine_software_16_x11_args(int argc, char **argv);
|
Eina_Bool engine_software_16_x11_args(const char *engine, int width, int height);
|
||||||
void engine_software_16_x11_loop(void);
|
void engine_software_16_x11_loop(void);
|
||||||
void engine_software_16_x11_shutdown(void);
|
void engine_software_16_x11_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -171,8 +171,8 @@ MainWndProc(HWND hwnd,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_software_ddraw_args(int argc, char **argv)
|
engine_software_ddraw_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
WNDCLASS wc;
|
WNDCLASS wc;
|
||||||
RECT rect;
|
RECT rect;
|
||||||
|
@ -182,17 +182,6 @@ engine_software_ddraw_args(int argc, char **argv)
|
||||||
DWORD exstyle;
|
DWORD exstyle;
|
||||||
int depth;
|
int depth;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "ddraw")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
instance = GetModuleHandle(NULL);
|
instance = GetModuleHandle(NULL);
|
||||||
if (!instance) return 0;
|
if (!instance) return 0;
|
||||||
|
@ -216,8 +205,8 @@ engine_software_ddraw_args(int argc, char **argv)
|
||||||
|
|
||||||
rect.left = 0;
|
rect.left = 0;
|
||||||
rect.top = 0;
|
rect.top = 0;
|
||||||
rect.right = win_w;
|
rect.right = width;
|
||||||
rect.bottom = win_h;
|
rect.bottom = height;
|
||||||
AdjustWindowRectEx (&rect, style, FALSE, exstyle);
|
AdjustWindowRectEx (&rect, style, FALSE, exstyle);
|
||||||
|
|
||||||
window = CreateWindowEx(exstyle,
|
window = CreateWindowEx(exstyle,
|
||||||
|
|
|
@ -6,8 +6,7 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Eina_Bool engine_software_ddraw_args(const char *engine, int width, int height);
|
||||||
int engine_software_ddraw_args(int argc, char **argv);
|
|
||||||
void engine_software_ddraw_loop(void);
|
void engine_software_ddraw_loop(void);
|
||||||
void engine_software_ddraw_shutdown(void);
|
void engine_software_ddraw_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -171,8 +171,8 @@ MainWndProc(HWND hwnd,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_software_gdi_args(int argc, char **argv)
|
engine_software_gdi_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
WNDCLASS wc;
|
WNDCLASS wc;
|
||||||
RECT rect;
|
RECT rect;
|
||||||
|
@ -182,20 +182,9 @@ engine_software_gdi_args(int argc, char **argv)
|
||||||
DWORD exstyle;
|
DWORD exstyle;
|
||||||
int depth;
|
int depth;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "gdi")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
instance = GetModuleHandle(NULL);
|
instance = GetModuleHandle(NULL);
|
||||||
if (!instance) return 0;
|
if (!instance) return EINA_FALSE;
|
||||||
|
|
||||||
wc.style = CS_HREDRAW | CS_VREDRAW;
|
wc.style = CS_HREDRAW | CS_VREDRAW;
|
||||||
wc.lpfnWndProc = MainWndProc;
|
wc.lpfnWndProc = MainWndProc;
|
||||||
|
@ -216,8 +205,8 @@ engine_software_gdi_args(int argc, char **argv)
|
||||||
|
|
||||||
rect.left = 0;
|
rect.left = 0;
|
||||||
rect.top = 0;
|
rect.top = 0;
|
||||||
rect.right = win_w;
|
rect.right = width;
|
||||||
rect.bottom = win_h;
|
rect.bottom = height;
|
||||||
AdjustWindowRectEx (&rect, style, FALSE, exstyle);
|
AdjustWindowRectEx (&rect, style, FALSE, exstyle);
|
||||||
|
|
||||||
window = CreateWindowEx(exstyle,
|
window = CreateWindowEx(exstyle,
|
||||||
|
@ -266,7 +255,7 @@ engine_software_gdi_args(int argc, char **argv)
|
||||||
ShowWindow(window, SW_SHOWDEFAULT);
|
ShowWindow(window, SW_SHOWDEFAULT);
|
||||||
UpdateWindow(window);
|
UpdateWindow(window);
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
DestroyWindow(window);
|
DestroyWindow(window);
|
||||||
|
@ -275,7 +264,7 @@ engine_software_gdi_args(int argc, char **argv)
|
||||||
free_library:
|
free_library:
|
||||||
FreeLibrary(instance);
|
FreeLibrary(instance);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -6,8 +6,7 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Eina_Bool engine_software_gdi_args(const char *engine, int width, int height);
|
||||||
int engine_software_gdi_args(int argc, char **argv);
|
|
||||||
void engine_software_gdi_loop(void);
|
void engine_software_gdi_loop(void);
|
||||||
void engine_software_gdi_shutdown(void);
|
void engine_software_gdi_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -4,26 +4,19 @@
|
||||||
#include <SDL/SDL.h>
|
#include <SDL/SDL.h>
|
||||||
#include <Evas_Engine_SDL.h>
|
#include <Evas_Engine_SDL.h>
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_software_sdl_args(int argc, char **argv)
|
engine_software_sdl_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
Evas_Engine_Info_SDL *einfo;
|
Evas_Engine_Info_SDL *einfo;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
int ok = 0;
|
||||||
|
|
||||||
for (i = 1; i < argc; ++i)
|
if (!strcmp(engine, "sdl")) ok = 1;
|
||||||
{
|
if (!strcmp(engine, "sdl-16")) ok = 2;
|
||||||
if ((!strcmp(argv[i], "-e") && (i < (argc - 1))))
|
if (!ok) return EINA_FALSE;
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "sdl")) ok = 1;
|
|
||||||
if (!strcmp(argv[i], "sdl-16")) ok = 2;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
if (ok == 1)
|
if (ok == 1)
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("software_sdl"));
|
evas_output_method_set(evas, evas_render_method_lookup("software_sdl"));
|
||||||
else
|
else
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("software_16_sdl"));
|
evas_output_method_set(evas, evas_render_method_lookup("software_16_sdl"));
|
||||||
|
|
||||||
|
@ -36,10 +29,10 @@ engine_software_sdl_args(int argc, char **argv)
|
||||||
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
|
||||||
{
|
{
|
||||||
printf("Evas can not setup the informations of the Software SDL Engine\n");
|
printf("Evas can not setup the informations of the Software SDL Engine\n");
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_SOFTWARE_SDL_H
|
#ifndef ENGINE_SOFTWARE_SDL_H
|
||||||
#define ENGINE_SOFTWARE_SDL_H
|
#define ENGINE_SOFTWARE_SDL_H
|
||||||
|
|
||||||
int engine_software_sdl_args(int argc, char **argv);
|
Eina_Bool engine_software_sdl_args(const char *engine, int width, int height);
|
||||||
void engine_software_sdl_loop(void);
|
void engine_software_sdl_loop(void);
|
||||||
void engine_software_sdl_shutdown(void);
|
void engine_software_sdl_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -38,8 +38,8 @@ static xcb_screen_t *screen = NULL;
|
||||||
static xcb_window_t win = 0;
|
static xcb_window_t win = 0;
|
||||||
static int first_expose = 0;
|
static int first_expose = 0;
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_software_xcb_args(int argc, char **argv)
|
engine_software_xcb_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
struct xcb_size_hints_t hints;
|
struct xcb_size_hints_t hints;
|
||||||
uint32_t value_list[6];
|
uint32_t value_list[6];
|
||||||
|
@ -63,20 +63,9 @@ engine_software_xcb_args(int argc, char **argv)
|
||||||
int l1;
|
int l1;
|
||||||
int l2;
|
int l2;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "xcb")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
conn = xcb_connect(NULL, &s);
|
conn = xcb_connect(NULL, &s);
|
||||||
if (xcb_connection_has_error(conn)) return 0;
|
if (xcb_connection_has_error(conn)) return EINA_FALSE;
|
||||||
|
|
||||||
cookie1 = xcb_intern_atom_unchecked(conn, 0, strlen("STRING"), "STRING");
|
cookie1 = xcb_intern_atom_unchecked(conn, 0, strlen("STRING"), "STRING");
|
||||||
cookie2 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_NAME"), "WM_NAME");
|
cookie2 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_NAME"), "WM_NAME");
|
||||||
|
@ -131,7 +120,7 @@ engine_software_xcb_args(int argc, char **argv)
|
||||||
goto close_connection;
|
goto close_connection;
|
||||||
xcb_create_window(conn,
|
xcb_create_window(conn,
|
||||||
einfo->info.depth,
|
einfo->info.depth,
|
||||||
win, screen->root, 0, 0, win_w, win_h, 0,
|
win, screen->root, 0, 0, width, height, 0,
|
||||||
XCB_WINDOW_CLASS_INPUT_OUTPUT,
|
XCB_WINDOW_CLASS_INPUT_OUTPUT,
|
||||||
((xcb_visualtype_t *)einfo->info.visual)->visual_id,
|
((xcb_visualtype_t *)einfo->info.visual)->visual_id,
|
||||||
value_mask,
|
value_mask,
|
||||||
|
@ -150,10 +139,10 @@ engine_software_xcb_args(int argc, char **argv)
|
||||||
|
|
||||||
memset(&hints, 0, sizeof(hints));
|
memset(&hints, 0, sizeof(hints));
|
||||||
hints.flags = XCB_SIZE_US_SIZE_HINT | XCB_SIZE_P_SIZE_HINT | XCB_SIZE_P_MIN_SIZE_HINT | XCB_SIZE_P_MAX_SIZE_HINT;
|
hints.flags = XCB_SIZE_US_SIZE_HINT | XCB_SIZE_P_SIZE_HINT | XCB_SIZE_P_MIN_SIZE_HINT | XCB_SIZE_P_MAX_SIZE_HINT;
|
||||||
hints.min_width = win_w;
|
hints.min_width = width;
|
||||||
hints.max_width = win_w;
|
hints.max_width = width;
|
||||||
hints.min_height = win_h;
|
hints.min_height = height;
|
||||||
hints.max_height = win_h;
|
hints.max_height = height;
|
||||||
|
|
||||||
reply = xcb_intern_atom_reply(conn, cookie1, NULL);
|
reply = xcb_intern_atom_reply(conn, cookie1, NULL);
|
||||||
string = reply->atom;
|
string = reply->atom;
|
||||||
|
@ -191,7 +180,7 @@ engine_software_xcb_args(int argc, char **argv)
|
||||||
|
|
||||||
while (!first_expose)
|
while (!first_expose)
|
||||||
engine_software_xcb_loop();
|
engine_software_xcb_loop();
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
xcb_destroy_window(conn, win);
|
xcb_destroy_window(conn, win);
|
||||||
|
@ -203,7 +192,7 @@ engine_software_xcb_args(int argc, char **argv)
|
||||||
free(xcb_intern_atom_reply(conn, cookie5, NULL));
|
free(xcb_intern_atom_reply(conn, cookie5, NULL));
|
||||||
xcb_disconnect(conn);
|
xcb_disconnect(conn);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_SOFTWARE_XCB_H
|
#ifndef ENGINE_SOFTWARE_XCB_H
|
||||||
#define ENGINE_SOFTWARE_XCB_H
|
#define ENGINE_SOFTWARE_XCB_H
|
||||||
|
|
||||||
int engine_software_xcb_args(int argc, char **argv);
|
Eina_Bool engine_software_xcb_args(const char *engine, int width, int height);
|
||||||
void engine_software_xcb_loop(void);
|
void engine_software_xcb_loop(void);
|
||||||
void engine_software_xcb_shutdown(void);
|
void engine_software_xcb_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -8,28 +8,17 @@ static Display *disp = NULL;
|
||||||
static Window win = 0;
|
static Window win = 0;
|
||||||
static int first_expose = 0;
|
static int first_expose = 0;
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_software_xlib_args(int argc, char **argv)
|
engine_software_xlib_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
XSetWindowAttributes attr;
|
XSetWindowAttributes attr;
|
||||||
XClassHint chint;
|
XClassHint chint;
|
||||||
XSizeHints szhints;
|
XSizeHints szhints;
|
||||||
Evas_Engine_Info_Software_X11 *einfo;
|
Evas_Engine_Info_Software_X11 *einfo;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "xlib")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
disp = XOpenDisplay(NULL);
|
disp = XOpenDisplay(NULL);
|
||||||
if (!disp) return 0;
|
if (!disp) return EINA_FALSE;
|
||||||
|
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("software_x11"));
|
evas_output_method_set(evas, evas_render_method_lookup("software_x11"));
|
||||||
einfo = (Evas_Engine_Info_Software_X11 *)evas_engine_info_get(evas);
|
einfo = (Evas_Engine_Info_Software_X11 *)evas_engine_info_get(evas);
|
||||||
|
@ -57,7 +46,7 @@ engine_software_xlib_args(int argc, char **argv)
|
||||||
KeyPressMask | KeyReleaseMask;
|
KeyPressMask | KeyReleaseMask;
|
||||||
attr.bit_gravity = ForgetGravity;
|
attr.bit_gravity = ForgetGravity;
|
||||||
win = XCreateWindow(disp, DefaultRootWindow(disp),
|
win = XCreateWindow(disp, DefaultRootWindow(disp),
|
||||||
0, 0, win_w, win_h, 0,
|
0, 0, width, height, 0,
|
||||||
einfo->info.depth, InputOutput,
|
einfo->info.depth, InputOutput,
|
||||||
einfo->info.visual,
|
einfo->info.visual,
|
||||||
CWBackingStore | CWColormap |
|
CWBackingStore | CWColormap |
|
||||||
|
@ -79,21 +68,21 @@ engine_software_xlib_args(int argc, char **argv)
|
||||||
chint.res_class = "Expedite";
|
chint.res_class = "Expedite";
|
||||||
XSetClassHint(disp, win, &chint);
|
XSetClassHint(disp, win, &chint);
|
||||||
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
|
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
|
||||||
szhints.min_width = szhints.max_width = win_w;
|
szhints.min_width = szhints.max_width = width;
|
||||||
szhints.min_height = szhints.max_height = win_h;
|
szhints.min_height = szhints.max_height = height;
|
||||||
XSetWMNormalHints(disp, win, &szhints);
|
XSetWMNormalHints(disp, win, &szhints);
|
||||||
XMapWindow(disp, win);
|
XMapWindow(disp, win);
|
||||||
XSync(disp, False);
|
XSync(disp, False);
|
||||||
while (!first_expose)
|
while (!first_expose)
|
||||||
engine_software_xlib_loop();
|
engine_software_xlib_loop();
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
XDestroyWindow(disp, win);
|
XDestroyWindow(disp, win);
|
||||||
close_display:
|
close_display:
|
||||||
XCloseDisplay(disp);
|
XCloseDisplay(disp);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_SOFTWARE_XLIB_H
|
#ifndef ENGINE_SOFTWARE_XLIB_H
|
||||||
#define ENGINE_SOFTWARE_XLIB_H
|
#define ENGINE_SOFTWARE_XLIB_H
|
||||||
|
|
||||||
int engine_software_xlib_args(int argc, char **argv);
|
Eina_Bool engine_software_xlib_args(const char *engine, int width, int height);
|
||||||
void engine_software_xlib_loop(void);
|
void engine_software_xlib_loop(void);
|
||||||
void engine_software_xlib_shutdown(void);
|
void engine_software_xlib_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -8,28 +8,17 @@ static Display *disp = NULL;
|
||||||
static Window win = 0;
|
static Window win = 0;
|
||||||
static int first_expose = 0;
|
static int first_expose = 0;
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_xrender_x11_args(int argc, char **argv)
|
engine_xrender_x11_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
XSetWindowAttributes attr;
|
XSetWindowAttributes attr;
|
||||||
XClassHint chint;
|
XClassHint chint;
|
||||||
XSizeHints szhints;
|
XSizeHints szhints;
|
||||||
Evas_Engine_Info_XRender_X11 *einfo;
|
Evas_Engine_Info_XRender_X11 *einfo;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "xr")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
disp = XOpenDisplay(NULL);
|
disp = XOpenDisplay(NULL);
|
||||||
if (!disp) return 0;
|
if (!disp) return EINA_FALSE;
|
||||||
|
|
||||||
evas_output_method_set(evas, evas_render_method_lookup("xrender_x11"));
|
evas_output_method_set(evas, evas_render_method_lookup("xrender_x11"));
|
||||||
einfo = (Evas_Engine_Info_XRender_X11 *)evas_engine_info_get(evas);
|
einfo = (Evas_Engine_Info_XRender_X11 *)evas_engine_info_get(evas);
|
||||||
|
@ -52,7 +41,7 @@ engine_xrender_x11_args(int argc, char **argv)
|
||||||
KeyPressMask | KeyReleaseMask;
|
KeyPressMask | KeyReleaseMask;
|
||||||
attr.bit_gravity = ForgetGravity;
|
attr.bit_gravity = ForgetGravity;
|
||||||
win = XCreateWindow(disp, DefaultRootWindow(disp),
|
win = XCreateWindow(disp, DefaultRootWindow(disp),
|
||||||
0, 0, win_w, win_h, 0,
|
0, 0, width, height, 0,
|
||||||
0, InputOutput,
|
0, InputOutput,
|
||||||
einfo->info.visual,
|
einfo->info.visual,
|
||||||
CWBackingStore |
|
CWBackingStore |
|
||||||
|
@ -74,21 +63,21 @@ engine_xrender_x11_args(int argc, char **argv)
|
||||||
chint.res_class = "Expedite";
|
chint.res_class = "Expedite";
|
||||||
XSetClassHint(disp, win, &chint);
|
XSetClassHint(disp, win, &chint);
|
||||||
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
|
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
|
||||||
szhints.min_width = szhints.max_width = win_w;
|
szhints.min_width = szhints.max_width = width;
|
||||||
szhints.min_height = szhints.max_height = win_h;
|
szhints.min_height = szhints.max_height = height;
|
||||||
XSetWMNormalHints(disp, win, &szhints);
|
XSetWMNormalHints(disp, win, &szhints);
|
||||||
XMapWindow(disp, win);
|
XMapWindow(disp, win);
|
||||||
XSync(disp, False);
|
XSync(disp, False);
|
||||||
while (!first_expose)
|
while (!first_expose)
|
||||||
engine_xrender_x11_loop();
|
engine_xrender_x11_loop();
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
XDestroyWindow(disp, win);
|
XDestroyWindow(disp, win);
|
||||||
close_display:
|
close_display:
|
||||||
XCloseDisplay(disp);
|
XCloseDisplay(disp);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_XRENDER_X11_H
|
#ifndef ENGINE_XRENDER_X11_H
|
||||||
#define ENGINE_XRENDER_X11_H
|
#define ENGINE_XRENDER_X11_H
|
||||||
|
|
||||||
int engine_xrender_x11_args(int argc, char **argv);
|
Eina_Bool engine_xrender_x11_args(const char *engine, int width, int height);
|
||||||
void engine_xrender_x11_loop(void);
|
void engine_xrender_x11_loop(void);
|
||||||
void engine_xrender_x11_shutdown(void);
|
void engine_xrender_x11_shutdown(void);
|
||||||
|
|
||||||
|
|
|
@ -57,8 +57,8 @@ _engine_xrender_visual_get(xcb_connection_t *conn, xcb_screen_t *screen)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
Eina_Bool
|
||||||
engine_xrender_xcb_args(int argc, char **argv)
|
engine_xrender_xcb_args(const char *engine, int width, int height)
|
||||||
{
|
{
|
||||||
struct xcb_size_hints_t hints;
|
struct xcb_size_hints_t hints;
|
||||||
uint32_t value_list[6];
|
uint32_t value_list[6];
|
||||||
|
@ -82,20 +82,9 @@ engine_xrender_xcb_args(int argc, char **argv)
|
||||||
int l1;
|
int l1;
|
||||||
int l2;
|
int l2;
|
||||||
int i;
|
int i;
|
||||||
int ok = 0;
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
|
||||||
{
|
|
||||||
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
if (!strcmp(argv[i], "xrxcb")) ok = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!ok) return 0;
|
|
||||||
|
|
||||||
conn = xcb_connect(NULL, &s);
|
conn = xcb_connect(NULL, &s);
|
||||||
if (xcb_connection_has_error(conn)) return 0;
|
if (xcb_connection_has_error(conn)) return EINA_FALSE;
|
||||||
|
|
||||||
s_tmp = s;
|
s_tmp = s;
|
||||||
iter = xcb_setup_roots_iterator(xcb_get_setup(conn));
|
iter = xcb_setup_roots_iterator(xcb_get_setup(conn));
|
||||||
|
@ -140,7 +129,7 @@ engine_xrender_xcb_args(int argc, char **argv)
|
||||||
goto close_connection;
|
goto close_connection;
|
||||||
xcb_create_window(conn,
|
xcb_create_window(conn,
|
||||||
screen->root_depth,
|
screen->root_depth,
|
||||||
win, screen->root, 0, 0, win_w, win_h, 0,
|
win, screen->root, 0, 0, width, height, 0,
|
||||||
XCB_WINDOW_CLASS_INPUT_OUTPUT,
|
XCB_WINDOW_CLASS_INPUT_OUTPUT,
|
||||||
((xcb_visualtype_t *)einfo->info.visual)->visual_id,
|
((xcb_visualtype_t *)einfo->info.visual)->visual_id,
|
||||||
value_mask,
|
value_mask,
|
||||||
|
@ -195,16 +184,16 @@ engine_xrender_xcb_args(int argc, char **argv)
|
||||||
free(str);
|
free(str);
|
||||||
|
|
||||||
/* szhints.flags = PMinSize | PMaxSize | PSize | USSize; */
|
/* szhints.flags = PMinSize | PMaxSize | PSize | USSize; */
|
||||||
/* szhints.min_width = szhints.max_width = win_w; */
|
/* szhints.min_width = szhints.max_width = width; */
|
||||||
/* szhints.min_height = szhints.max_height = win_h; */
|
/* szhints.min_height = szhints.max_height = height; */
|
||||||
/* XSetWMNormalHints(disp, win, &szhints); */
|
/* XSetWMNormalHints(disp, win, &szhints); */
|
||||||
|
|
||||||
memset(&hints, 0, sizeof(hints));
|
memset(&hints, 0, sizeof(hints));
|
||||||
hints.flags = XCB_SIZE_US_SIZE_HINT | XCB_SIZE_P_SIZE_HINT | XCB_SIZE_P_MIN_SIZE_HINT | XCB_SIZE_P_MAX_SIZE_HINT;
|
hints.flags = XCB_SIZE_US_SIZE_HINT | XCB_SIZE_P_SIZE_HINT | XCB_SIZE_P_MIN_SIZE_HINT | XCB_SIZE_P_MAX_SIZE_HINT;
|
||||||
hints.min_width = win_w;
|
hints.min_width = width;
|
||||||
hints.max_width = win_w;
|
hints.max_width = width;
|
||||||
hints.min_height = win_h;
|
hints.min_height = height;
|
||||||
hints.max_height = win_h;
|
hints.max_height = height;
|
||||||
|
|
||||||
reply = xcb_intern_atom_reply(conn, cookie4, NULL);
|
reply = xcb_intern_atom_reply(conn, cookie4, NULL);
|
||||||
wm_normal_hint = reply->atom;
|
wm_normal_hint = reply->atom;
|
||||||
|
@ -222,14 +211,14 @@ engine_xrender_xcb_args(int argc, char **argv)
|
||||||
|
|
||||||
while (!first_expose)
|
while (!first_expose)
|
||||||
engine_xrender_xcb_loop();
|
engine_xrender_xcb_loop();
|
||||||
return 1;
|
return EINA_TRUE;
|
||||||
|
|
||||||
destroy_window:
|
destroy_window:
|
||||||
xcb_destroy_window(conn, win);
|
xcb_destroy_window(conn, win);
|
||||||
close_connection:
|
close_connection:
|
||||||
xcb_disconnect(conn);
|
xcb_disconnect(conn);
|
||||||
|
|
||||||
return 0;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef ENGINE_XRENDER_XCB_H
|
#ifndef ENGINE_XRENDER_XCB_H
|
||||||
#define ENGINE_XRENDER_XCB_H
|
#define ENGINE_XRENDER_XCB_H
|
||||||
|
|
||||||
int engine_xrender_xcb_args(int argc, char **argv);
|
Eina_Bool engine_xrender_xcb_args(const char *engine, int width, int height);
|
||||||
void engine_xrender_xcb_loop(void);
|
void engine_xrender_xcb_loop(void);
|
||||||
void engine_xrender_xcb_shutdown(void);
|
void engine_xrender_xcb_shutdown(void);
|
||||||
|
|
||||||
|
|
374
src/bin/main.c
374
src/bin/main.c
|
@ -1130,41 +1130,142 @@ _engine_go(void)
|
||||||
{
|
{
|
||||||
return go;
|
return go;
|
||||||
}
|
}
|
||||||
|
static const Expedite_Engine engines[] = {
|
||||||
|
#if HAVE_EVAS_SOFTWARE_XLIB
|
||||||
|
{ "xlib", engine_software_xlib_args, engine_software_xlib_loop, engine_software_xlib_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_XRENDER_X11
|
||||||
|
{ "xr", engine_xrender_x11_args, engine_xrender_x11_loop, engine_xrender_x11_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_OPENGL_X11
|
||||||
|
{ "gl", engine_gl_x11_args, engine_gl_x11_loop, engine_gl_x11_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_SOFTWARE_XCB
|
||||||
|
{ "xcb", engine_software_xcb_args, engine_software_xcb_loop, engine_software_xcb_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_XRENDER_XCB
|
||||||
|
{ "xrxcb", engine_xrender_xcb_args, engine_xrender_xcb_loop, engine_xrender_xcb_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_SOFTWARE_GDI
|
||||||
|
{ "gdi", engine_software_gdi_args, engine_software_gdi_loop, engine_software_gdi_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_SOFTWARE_DDRAW
|
||||||
|
{ "ddraw", engine_software_ddraw_args, engine_software_ddraw_loop, engine_software_ddraw_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_DIRECT3D
|
||||||
|
{ "direct3d",engine_direct3d_args, engine_direct3d_loop, engine_direct3d_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_OPENGL_GLEW
|
||||||
|
{ "glew" , engine_gl_glew_args, engine_gl_glew_loop, engine_gl_glew_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_SOFTWARE_SDL
|
||||||
|
{ "sdl", engine_software_sdl_args, engine_software_sdl_loop, engine_software_sdl_shutdown },
|
||||||
|
{ "sdl-16",engine_software_sdl_args, engine_software_sdl_loop, engine_software_sdl_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_OPENGL_SDL
|
||||||
|
{ "gl-sdl",engine_gl_sdl_args, engine_gl_sdl_loop, engine_gl_sdl_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_FB
|
||||||
|
{ "fb", engine_fb_args, engine_fb_loop, engine_fb_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_DIRECTFB
|
||||||
|
{ "directfb",engine_directfb_args, engine_directfb_loop, engine_directfb_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_QUARTZ
|
||||||
|
{ "quartz",engine_quartz_args, engine_quartz_loop, engine_quartz_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_SOFTWARE_16_X11
|
||||||
|
{ "x11-16",engine_software_16_x11_args, engine_software_16_x11_loop, engine_software_16_x11_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_SOFTWARE_16_DDRAW
|
||||||
|
{ "ddraw-16",engine_software_16_ddraw_args, engine_software_16_ddraw_loop, engine_software_16_ddraw_shutdown },
|
||||||
|
#endif
|
||||||
|
#if HAVE_EVAS_SOFTWARE_16_WINCE
|
||||||
|
{ "wince", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
|
||||||
|
{ "wince-fb", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
|
||||||
|
{ "wince-gapi", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
|
||||||
|
{ "wince-ddraw", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
|
||||||
|
{ "wince-gdi", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
|
||||||
|
#endif
|
||||||
|
{ NULL, NULL, NULL, NULL }
|
||||||
|
};
|
||||||
|
|
||||||
|
static const Expedite_Resolution resolutions[] = {
|
||||||
|
{ "qvga", 320 , 240 },
|
||||||
|
{ "qvga-p", 240 , 320 },
|
||||||
|
{ "hvga", 320 , 480 },
|
||||||
|
{ "hvga-p", 480 , 320 },
|
||||||
|
{ "vga", 640 , 480 },
|
||||||
|
{ "vga-p", 480 , 640 },
|
||||||
|
{ "wvga", 800 , 480 },
|
||||||
|
{ "wvga-p", 480 , 800 },
|
||||||
|
{ "svga", 800 , 600 },
|
||||||
|
{ "svga-p", 600 , 800 },
|
||||||
|
{ "xga", 1024, 768 },
|
||||||
|
{ "xga-p", 768 , 1024},
|
||||||
|
{ "wxga", 1280, 768 },
|
||||||
|
{ "wxga-p", 768 , 1280},
|
||||||
|
{ "n800", 720 , 420 },
|
||||||
|
{ "pal", 720 , 576 },
|
||||||
|
{ "720p", 1280, 720 },
|
||||||
|
{ "wsvga", 1024, 600 },
|
||||||
|
{ "wsvga-p", 600 , 1024},
|
||||||
|
{ NULL, 0, 0 }
|
||||||
|
};
|
||||||
|
|
||||||
|
static void
|
||||||
|
_help(void)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
fprintf(stderr,
|
||||||
|
"No engine selected.\n"
|
||||||
|
"\n"
|
||||||
|
"Options:\n"
|
||||||
|
" -datadir path/to/data\n"
|
||||||
|
" -a (autorun all tests)\n"
|
||||||
|
" -c NUM (loop count for test)\n"
|
||||||
|
" -l (list tests)\n"
|
||||||
|
" -t TEST-NUM\n"
|
||||||
|
" -e ENGINE\n"
|
||||||
|
" -p PROFILE\n"
|
||||||
|
"\n"
|
||||||
|
"Where ENGINE can be one of:\n"
|
||||||
|
" ");
|
||||||
|
for (i = 0; engines[i].name != NULL; ++i)
|
||||||
|
fprintf(stderr, " %s", engines[i].name);
|
||||||
|
|
||||||
|
fprintf(stderr,
|
||||||
|
"\n"
|
||||||
|
"Where PROFILE can be one of:\n");
|
||||||
|
|
||||||
|
for (i = 0; resolutions[i].name != NULL; ++i)
|
||||||
|
fprintf(stderr, " %s", resolutions[i].name);
|
||||||
|
|
||||||
|
fprintf(stderr, "\n");
|
||||||
|
exit(-1);
|
||||||
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
_profile_parse(int argc, char **argv)
|
_profile_parse(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int i;
|
int i, j;
|
||||||
|
|
||||||
for (i = 1; i < argc; i++)
|
for (i = 1; i < argc; i++)
|
||||||
{
|
{
|
||||||
if ((!strcmp(argv[i], "-p")) && (i < (argc - 1)))
|
if ((!strcmp(argv[i], "-p")) && (i < (argc - 1)))
|
||||||
{
|
{
|
||||||
i++;
|
i++;
|
||||||
if (!strcmp(argv[i], "qvga")) {win_w = 320 ; win_h = 240 ;}
|
for (j = 0; resolutions[j].name != NULL; ++j)
|
||||||
else if (!strcmp(argv[i], "qvga-p")) {win_w = 240 ; win_h = 320 ;}
|
if (!strcmp(argv[i], resolutions[j].name))
|
||||||
else if (!strcmp(argv[i], "hvga")) {win_w = 320 ; win_h = 480 ;}
|
{
|
||||||
else if (!strcmp(argv[i], "hvga-p")) {win_w = 480 ; win_h = 320 ;}
|
win_w = resolutions[j].width;
|
||||||
else if (!strcmp(argv[i], "vga")) {win_w = 640 ; win_h = 480 ;}
|
win_h = resolutions[j].height;
|
||||||
else if (!strcmp(argv[i], "vga-p")) {win_w = 480 ; win_h = 640 ;}
|
break;
|
||||||
else if (!strcmp(argv[i], "wvga")) {win_w = 800 ; win_h = 480 ;}
|
}
|
||||||
else if (!strcmp(argv[i], "wvga-p")) {win_w = 480 ; win_h = 800 ;}
|
|
||||||
else if (!strcmp(argv[i], "svga")) {win_w = 800 ; win_h = 600 ;}
|
if (resolutions[j].name == NULL)
|
||||||
else if (!strcmp(argv[i], "svga-p")) {win_w = 600 ; win_h = 800 ;}
|
_help();
|
||||||
else if (!strcmp(argv[i], "xga")) {win_w = 1024; win_h = 768 ;}
|
|
||||||
else if (!strcmp(argv[i], "xga-p")) {win_w = 768 ; win_h = 1024;}
|
|
||||||
else if (!strcmp(argv[i], "wxga")) {win_w = 1280; win_h = 768 ;}
|
|
||||||
else if (!strcmp(argv[i], "wxga-p")) {win_w = 768 ; win_h = 1280;}
|
|
||||||
else if (!strcmp(argv[i], "n800")) {win_w = 720 ; win_h = 420 ;}
|
|
||||||
else if (!strcmp(argv[i], "pal")) {win_w = 720 ; win_h = 576 ;}
|
|
||||||
else if (!strcmp(argv[i], "720p")) {win_w = 1280; win_h = 720 ;}
|
|
||||||
else if (!strcmp(argv[i], "wsvga")) {win_w = 1024; win_h = 600 ;}
|
|
||||||
else if (!strcmp(argv[i], "wsvga-p")){win_w = 600 ; win_h = 1024;}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
printf("Invalid profile: %s\n", argv[i]);
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else if ((!strcmp(argv[i], "-c")) && (i < (argc - 1)))
|
else if ((!strcmp(argv[i], "-c")) && (i < (argc - 1)))
|
||||||
{
|
{
|
||||||
|
@ -1195,206 +1296,33 @@ _engine_args(int argc, char **argv)
|
||||||
char buf[4096];
|
char buf[4096];
|
||||||
char *prefix;
|
char *prefix;
|
||||||
int profile_ok;
|
int profile_ok;
|
||||||
|
int i, j;
|
||||||
|
|
||||||
/* FIXME: parse args for geometry, engine etc. */
|
/* FIXME: parse args for geometry, engine etc. */
|
||||||
profile_ok = _profile_parse(argc, argv);
|
profile_ok = _profile_parse(argc, argv);
|
||||||
#if HAVE_EVAS_SOFTWARE_XLIB
|
|
||||||
if (engine_software_xlib_args(argc, argv))
|
evas_output_size_set(evas, win_w, win_h);
|
||||||
{
|
evas_output_viewport_set(evas, 0, 0, win_w, win_h);
|
||||||
loop_func = engine_software_xlib_loop;
|
|
||||||
shutdown_func = engine_software_xlib_shutdown;
|
for (i = 1; i < argc; ++i)
|
||||||
}
|
if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
|
||||||
#endif
|
{
|
||||||
#if HAVE_EVAS_XRENDER_X11
|
++i;
|
||||||
if (engine_xrender_x11_args(argc, argv))
|
|
||||||
{
|
for (j = 0; engines[j].name != NULL; ++j)
|
||||||
loop_func = engine_xrender_x11_loop;
|
if (!strcmp(argv[i], engines[j].name))
|
||||||
shutdown_func = engine_xrender_x11_shutdown;
|
{
|
||||||
}
|
if (engines[j].init(engines[j].name, win_w, win_h))
|
||||||
#endif
|
{
|
||||||
#if HAVE_EVAS_OPENGL_X11
|
loop_func = engines[j].loop;
|
||||||
if (engine_gl_x11_args(argc, argv))
|
shutdown_func = engines[j].shutdown;
|
||||||
{
|
}
|
||||||
loop_func = engine_gl_x11_loop;
|
break;
|
||||||
shutdown_func = engine_gl_x11_shutdown;
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_XCB
|
|
||||||
if (engine_software_xcb_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_software_xcb_loop;
|
|
||||||
shutdown_func = engine_software_xcb_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_XRENDER_XCB
|
|
||||||
if (engine_xrender_xcb_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_xrender_xcb_loop;
|
|
||||||
shutdown_func = engine_xrender_xcb_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_GDI
|
|
||||||
if (engine_software_gdi_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_software_gdi_loop;
|
|
||||||
shutdown_func = engine_software_gdi_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_DDRAW
|
|
||||||
if (engine_software_ddraw_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_software_ddraw_loop;
|
|
||||||
shutdown_func = engine_software_ddraw_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_DIRECT3D
|
|
||||||
if (engine_direct3d_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_direct3d_loop;
|
|
||||||
shutdown_func = engine_direct3d_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_OPENGL_GLEW
|
|
||||||
if (engine_gl_glew_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_gl_glew_loop;
|
|
||||||
shutdown_func = engine_gl_glew_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_SDL
|
|
||||||
if (engine_software_sdl_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_software_sdl_loop;
|
|
||||||
shutdown_func = engine_software_sdl_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_OPENGL_SDL
|
|
||||||
if (engine_gl_sdl_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_gl_sdl_loop;
|
|
||||||
shutdown_func = engine_gl_sdl_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_FB
|
|
||||||
if (engine_fb_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_fb_loop;
|
|
||||||
shutdown_func = engine_fb_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_DIRECTFB
|
|
||||||
if (engine_directfb_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_directfb_loop;
|
|
||||||
shutdown_func = engine_directfb_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_QUARTZ
|
|
||||||
if (engine_quartz_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_quartz_loop;
|
|
||||||
shutdown_func = engine_quartz_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_16_X11
|
|
||||||
if (engine_software_16_x11_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_software_16_x11_loop;
|
|
||||||
shutdown_func = engine_software_16_x11_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_16_DDRAW
|
|
||||||
if (engine_software_16_ddraw_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_software_16_ddraw_loop;
|
|
||||||
shutdown_func = engine_software_16_ddraw_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_16_WINCE
|
|
||||||
if (engine_software_16_wince_args(argc, argv))
|
|
||||||
{
|
|
||||||
loop_func = engine_software_16_wince_loop;
|
|
||||||
shutdown_func = engine_software_16_wince_shutdown;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
if ((!loop_func) || (!profile_ok))
|
if ((!loop_func) || (!profile_ok))
|
||||||
{
|
_help();
|
||||||
fprintf(stderr,
|
|
||||||
"No engine selected.\n"
|
|
||||||
"\n"
|
|
||||||
"Options:\n"
|
|
||||||
" -datadir path/to/data\n"
|
|
||||||
" -a (autorun all tests)\n"
|
|
||||||
" -c NUM (loop count for test)\n"
|
|
||||||
" -l (list tests)\n"
|
|
||||||
" -t TEST-NUM\n"
|
|
||||||
" -e ENGINE\n"
|
|
||||||
" -p PROFILE\n"
|
|
||||||
"\n"
|
|
||||||
"Where ENGINE can be one of:\n"
|
|
||||||
" "
|
|
||||||
#if HAVE_EVAS_SOFTWARE_XLIB
|
|
||||||
" xlib"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_XRENDER_X11
|
|
||||||
" xr"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_OPENGL_X11
|
|
||||||
" gl"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_XCB
|
|
||||||
" xcb"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_XRENDER_XCB
|
|
||||||
" xrxcb"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_GDI
|
|
||||||
" gdi"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_DDRAW
|
|
||||||
" ddraw"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_DIRECT3D
|
|
||||||
" direct3d"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_QUARTZ
|
|
||||||
" quartz"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_OPENGL_GLEW
|
|
||||||
" gl-glew"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_SDL
|
|
||||||
" sdl sdl-16"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_OPENGL_SDL
|
|
||||||
" gl-sdl"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_FB
|
|
||||||
" fb"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_DIRECTFB
|
|
||||||
" directfb"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_16_X11
|
|
||||||
" x11-16"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_16_DDRAW
|
|
||||||
" ddraw-16"
|
|
||||||
#endif
|
|
||||||
#if HAVE_EVAS_SOFTWARE_16_WINCE
|
|
||||||
" wince"
|
|
||||||
" wince-fb"
|
|
||||||
" wince-gapi"
|
|
||||||
" wince-ddraw"
|
|
||||||
" wince-gdi"
|
|
||||||
#endif
|
|
||||||
"\n"
|
|
||||||
"Where PROFILE can be one of:\n"
|
|
||||||
" qvga qvga-p hvga hvga-p vga vga-p wvga wvga-p svga svga-p xga xga-p\n"
|
|
||||||
" wxga wxga-p n800 pal 720p wsvga wsvga-p\n"
|
|
||||||
);
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
|
|
||||||
datadir = _datadir_parse(argc, argv);
|
datadir = _datadir_parse(argc, argv);
|
||||||
|
|
||||||
|
@ -1406,8 +1334,6 @@ _engine_args(int argc, char **argv)
|
||||||
|
|
||||||
snprintf(buf, 4096, "%s", prefix);
|
snprintf(buf, 4096, "%s", prefix);
|
||||||
|
|
||||||
evas_output_size_set(evas, win_w, win_h);
|
|
||||||
evas_output_viewport_set(evas, 0, 0, win_w, win_h);
|
|
||||||
evas_key_modifier_add(evas, "Shift");
|
evas_key_modifier_add(evas, "Shift");
|
||||||
evas_key_modifier_add(evas, "Control");
|
evas_key_modifier_add(evas, "Control");
|
||||||
evas_key_modifier_add(evas, "Alt");
|
evas_key_modifier_add(evas, "Alt");
|
||||||
|
@ -1416,7 +1342,7 @@ _engine_args(int argc, char **argv)
|
||||||
evas_key_lock_add(evas, "Num_Lock");
|
evas_key_lock_add(evas, "Num_Lock");
|
||||||
evas_key_lock_add(evas, "Scroll_Lock");
|
evas_key_lock_add(evas, "Scroll_Lock");
|
||||||
evas_font_path_append(evas, buf);
|
evas_font_path_append(evas, buf);
|
||||||
// BLAH
|
// BLAH
|
||||||
// evas_image_cache_set(evas, 4 * 1024 * 1024);
|
// evas_image_cache_set(evas, 4 * 1024 * 1024);
|
||||||
// evas_font_cache_set(evas, 1 * 1024 * 1024);
|
// evas_font_cache_set(evas, 1 * 1024 * 1024);
|
||||||
}
|
}
|
||||||
|
|
|
@ -88,6 +88,24 @@ extern Evas *evas;
|
||||||
extern int win_w, win_h;
|
extern int win_w, win_h;
|
||||||
extern int loops;
|
extern int loops;
|
||||||
|
|
||||||
|
typedef struct _Expedite_Resolution Expedite_Resolution;
|
||||||
|
typedef struct _Expedite_Engine Expedite_Engine;
|
||||||
|
|
||||||
|
struct _Expedite_Resolution
|
||||||
|
{
|
||||||
|
const char *name;
|
||||||
|
int width;
|
||||||
|
int height;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct _Expedite_Engine
|
||||||
|
{
|
||||||
|
const char *name;
|
||||||
|
Eina_Bool (*init)(const char *engine, int width, int height);
|
||||||
|
void (*loop)(void);
|
||||||
|
void (*shutdown)(void);
|
||||||
|
};
|
||||||
|
|
||||||
void srnd(void);
|
void srnd(void);
|
||||||
unsigned int rnd(void);
|
unsigned int rnd(void);
|
||||||
double get_time(void);
|
double get_time(void);
|
||||||
|
|
Loading…
Reference in New Issue