win32: fix osd compositing pipeline for singlecore

This commit is contained in:
zeromus 2009-08-10 03:29:43 +00:00
parent a39c62b129
commit d5b938452c
5 changed files with 21 additions and 21 deletions

View File

@ -15,6 +15,7 @@ adelikat
matusz matusz
pa__ pa__
gocha gocha
nitsuja
Contributors Contributors
------------ ------------
@ -40,4 +41,3 @@ Thanks to our super testers for this release
nash679 nash679
pokefan999 pokefan999
dottorleo dottorleo
lbalbalba

View File

@ -11,6 +11,7 @@ General/Core:
bug: fix cflash directory support for non-windows bug: fix cflash directory support for non-windows
bug: fix freeze in cart irq bug: fix freeze in cart irq
bug: correctly emulate dma to/from tcm bug: correctly emulate dma to/from tcm
bug: fix in thumb LSR carryflag
enh: add guitar grip emulation enh: add guitar grip emulation
enh: add more powerful antigrain-based drawing library and rewrite OSD system enh: add more powerful antigrain-based drawing library and rewrite OSD system
enh: ideas-style debugging prints enh: ideas-style debugging prints
@ -23,6 +24,7 @@ Graphics:
bug: fix color overflow in capture blending bug: fix color overflow in capture blending
bug: fix disp fifo capture bug: fix disp fifo capture
bug: fix simultaneous vram display and capture via same bank bug: fix simultaneous vram display and capture via same bank
bug: fix 3d overflow acknowledge registers
bug: change 3d cores to use 18bit color bug: change 3d cores to use 18bit color
bug: swrast: add clear image and scroll emulation bug: swrast: add clear image and scroll emulation
bug: swrast: add fog emulation bug: swrast: add fog emulation

View File

@ -120,7 +120,7 @@ static void Agg_init_fonts()
AggDraw_Desmume aggDraw; AggDraw_Desmume aggDraw;
T_AGG_RGB555 agg_targetScreen(GPU_screen, 256, 384, 512); T_AGG_RGBA agg_targetScreen(0, 256, 384, 1024);
static u32 luaBuffer[256*192*2]; static u32 luaBuffer[256*192*2];
T_AGG_RGBA agg_targetLua((u8*)luaBuffer, 256, 384, 1024); T_AGG_RGBA agg_targetLua((u8*)luaBuffer, 256, 384, 1024);

View File

@ -1,6 +1,7 @@
/* AboutBox.cpp /* AboutBox.cpp
Copyright (C) 2008-2009 shash Copyright (C) 2008-2009 shash
Copyright (C) 2009 DeSmuME team
This file is part of DeSmuME This file is part of DeSmuME
@ -43,6 +44,7 @@ const char *team[] = {
"matusz", "matusz",
"pa__", "pa__",
"gocha", "gocha",
"nitsuja",
"", "",
"Contributors", "Contributors",
"------------", "------------",
@ -67,7 +69,6 @@ const char *team[] = {
"nash679", "nash679",
"pokefan999", "pokefan999",
"dottorleo", "dottorleo",
"lbalbalba",
"", "",
"average time from bug checkin to bugreport:", "average time from bug checkin to bugreport:",
"23 seconds", "23 seconds",

View File

@ -165,9 +165,6 @@ extern LRESULT CALLBACK RamSearchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARA
void InitRamSearch(); void InitRamSearch();
void FilterUpdate(HWND hwnd, bool user=true); void FilterUpdate(HWND hwnd, bool user=true);
CACHE_ALIGN u8 GPU_screen_unmodified_buffer[4*256*192];
CRITICAL_SECTION win_execute_sync; CRITICAL_SECTION win_execute_sync;
volatile int win_sound_samplecounter = 0; volatile int win_sound_samplecounter = 0;
@ -871,18 +868,6 @@ static void DoDisplay(bool firstTime)
{ {
Lock lock (win_backbuffer_sync); Lock lock (win_backbuffer_sync);
if(firstTime)
{
//on single core systems, draw straight to the screen
//we only do this once per emulated frame because we don't want to waste time redrawing
//on such lousy computers
if(CommonSettings.single_core)
{
aggDraw.hud->attach(video.srcBuffer, 256, 384, 512);
DoDisplay_DrawHud();
}
}
//convert pixel format to 32bpp for compositing //convert pixel format to 32bpp for compositing
//why do we do this over and over? well, we are compositing to //why do we do this over and over? well, we are compositing to
//filteredbuffer32bpp, and it needs to get refreshed each frame.. //filteredbuffer32bpp, and it needs to get refreshed each frame..
@ -891,6 +876,18 @@ static void DoDisplay(bool firstTime)
for(int i=0;i<size;i++) for(int i=0;i<size;i++)
video.buffer[i] = RGB15TO24_REVERSE(src[i]); video.buffer[i] = RGB15TO24_REVERSE(src[i]);
if(firstTime)
{
//on single core systems, draw straight to the screen
//we only do this once per emulated frame because we don't want to waste time redrawing
//on such lousy computers
if(CommonSettings.single_core)
{
aggDraw.hud->attach((u8*)video.buffer, 256, 384, 1024);
DoDisplay_DrawHud();
}
}
//apply user's filter //apply user's filter
video.filter(); video.filter();
@ -952,8 +949,7 @@ void Display()
if(CommonSettings.single_core) if(CommonSettings.single_core)
{ {
memcpy(GPU_screen_unmodified_buffer,GPU_screen,256*192*4); video.srcBuffer = (u8*)GPU_screen;
video.srcBuffer = (u8*)GPU_screen_unmodified_buffer;
DoDisplay(true); DoDisplay(true);
} }
else else
@ -1890,10 +1886,11 @@ int _main()
KillDisplay(); KillDisplay();
SaveRecentRoms(); SaveRecentRoms();
NDS_DeInit();
DRV_AviEnd(); DRV_AviEnd();
WAV_End(); WAV_End();
NDS_DeInit();
//------SHUTDOWN //------SHUTDOWN
#ifdef DEBUG #ifdef DEBUG