/* ============================================================================ * @func KM_OS_init * * @desc This function creates a mem pool. * * @modif None * ============================================================================ */ NORMAL_API DSP_STATUS KM_OS_init( Char8 * strWidth, Char8 * strHeight ) { KM_0Print ("Entered KM_OS_init ()\n") ; DSP_STATUS status = DSP_SOK ; /* Init direct FB */ directfb_init(0, NULL) ; printf("DirectFB initialized\n"); /* Open camera device (/dev/video0) */ if (open_device () == 0) status = DSP_EFAIL ; /* Initialize device */ if (status == DSP_SOK && init_device ( atoi(strWidth), atoi(strHeight) ) == 0) status=DSP_EFAIL ; /* Start capturing */ if (status == DSP_SOK && start_capturing () == 0) status = DSP_EFAIL ; KM_0Print ("Leaving KM_OS_init ()\n") ; return status ; }
void giz_init(HINSTANCE hInstance, HINSTANCE hPrevInstance) { int ret; lprintf("\n\nPicoDrive v" VERSION " (c) notaz, 2006-2008\n"); lprintf("%s %s\n\n", __DATE__, __TIME__); ret = Framework_Init(hInstance, hPrevInstance); if (!ret) { lprintf("Framework_Init() failed\n"); exit(1); } ret = Framework2D_Init(); if (!ret) { lprintf("Framework2D_Init() failed\n"); exit(1); } #if 0 ret = directfb_init(); if (ret != 0) { lprintf("directfb_init() failed\n"); } #endif // test screen giz_screen = fb_lock(1); if (giz_screen == NULL) { lprintf("fb_lock() failed\n"); exit(1); } lprintf("fb_lock() returned %p\n", giz_screen); fb_unlock(); giz_screen = NULL; }