Mercurial > hg > Members > kono > Cerium
view Renderer/Engine/viewerFB.cc @ 603:42c94f85c779
long -> memaddr (64 or 32)
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Sat, 07 Nov 2009 14:13:29 +0900 |
parents | 735f76483bb2 |
children | 4f77768d7a7f |
line wrap: on
line source
#include "viewerFB.h" #include "Func.h" #include "fb.h" //extern void post2runLoop(void *); void ViewerFB::video_init(TaskManager *manager) { Uint32 sdl_flag = default_sdl_flag | SDL_INIT_VIDEO; if (SDL_Init(sdl_flag) < 0) { fprintf(stderr,"Couldn't initialize SDL: %s\n",SDL_GetError()); exit(1); } pixels = (Uint32*)get_fbdev_addr(); if (pixels == 0) { pixels = (new Uint32[width*height*32/8]); } } void ViewerFB::clean_pixels() { //bzero(pixels, sizeof(int)*width*height); //memset(pixels, 0xFF, sizeof(int)*width*height); }