void pgInit() { PSP2_Video_Init(); //sceDisplaySetMode(0,SCREEN_WIDTH,SCREEN_HEIGHT); pgScreenFrame(0,0); }
void I_InitGraphics(void) { static int firsttime=1; long video_w, video_h, w, h; long video_bpp; if (!firsttime) return; firsttime = 0; multiply = 1; if (M_CheckParm("-2")) multiply = 2; if (M_CheckParm("-3")) multiply = 3; // check if the user wants to grab the mouse (quite unnice) grabMouse = !!M_CheckParm("-grabmouse"); video_w = w = 320; video_h = h = 200; video_bpp = 8; PSP2_Video_Init(SCREEN_SCALE_NONE); screens[0] = PSP2_Video_GetVideoPtr(); //(unsigned char *) malloc(SCREENWIDTH * SCREENHEIGHT); //sceKernelDcacheWritebackAll(); //// setup GU // //sceGuInit(); //sceGuStart(0,list); //sceGuDrawBuffer(GU_PSM_8888,(void*)0,BUF_WIDTH); //sceGuDispBuffer(SCR_WIDTH,SCR_HEIGHT,(void*)FRAME_SIZE,BUF_WIDTH); //sceGuDepthBuffer((void*)(FRAME_SIZE*2),BUF_WIDTH); //sceGuOffset(2048 - (SCR_WIDTH/2),2048 - (SCR_HEIGHT/2)); //sceGuViewport(2048,2048,SCR_WIDTH,SCR_HEIGHT); //sceGuDepthRange(0xc350,0x2710); //sceGuScissor(0,0,SCR_WIDTH,SCR_HEIGHT); //sceGuEnable(GU_SCISSOR_TEST); //sceGuFrontFace(GU_CW); //sceGuEnable(GU_TEXTURE_2D); //sceGuClear(GU_COLOR_BUFFER_BIT|GU_DEPTH_BUFFER_BIT); //sceGuFinish(); //sceGuSync(0,0); //sceDisplayWaitVblankStart(); //pspDebugScreenClear(); //sceGuDisplay(GU_TRUE); }