MCPcopy Create free account
hub / github.com/TASEmulators/fceux / FCEU_PutImage

Function FCEU_PutImage

src/video.cpp:200–388  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

198}
199
200void FCEU_PutImage(void)
201{
202 if(dosnapsave==2) //Save screenshot as, currently only flagged & run by the Win32 build. //TODO SDL: implement this?
203 {
204 char nameo[512];
205 strcpy(nameo,FCEUI_GetSnapshotAsName().c_str());
206 if (nameo[0])
207 {
208 SaveSnapshot(nameo);
209 FCEU_DispMessage("Snapshot Saved.",0);
210 }
211 dosnapsave=0;
212 }
213 if(GameInfo->type==GIT_NSF)
214 {
215 DrawNSF(XBuf);
216
217#ifdef _S9XLUA_H
218 FCEU_LuaGui(XBuf);
219#endif
220
221 //Save snapshot after NSF screen is drawn. Why would we want to do it before?
222 if(dosnapsave==1)
223 {
224 ReallySnap();
225 dosnapsave=0;
226 }
227 }
228 else
229 {
230 //Save backbuffer before overlay stuff is written.
231 if(!FCEUI_EmulationPaused())
232 memcpy(XBackBuf, XBuf, 256*256);
233
234 //Some messages need to be displayed before the avi is dumped
235 DrawMessage(true);
236
237#ifdef _S9XLUA_H
238 // Lua gui should draw before the avi is dumped.
239 FCEU_LuaGui(XBuf);
240#endif
241
242 //Save snapshot
243 if(dosnapsave==1)
244 {
245 ReallySnap();
246 dosnapsave=0;
247 }
248
249 if (!FCEUI_AviEnableHUDrecording()) snapAVI();
250
251 if(GameInfo->type==GIT_VSUNI)
252 FCEU_VSUniDraw(XBuf);
253
254 FCEU_DrawSaveStates(XBuf);
255 FCEU_DrawMovies(XBuf);
256 FCEU_DrawLagCounter(XBuf);
257 FCEU_DrawNTSCControlBars(XBuf);

Callers 1

FCEUI_EmulateFunction · 0.85

Calls 15

FCEUI_GetSnapshotAsNameFunction · 0.85
SaveSnapshotFunction · 0.85
FCEU_DispMessageFunction · 0.85
DrawNSFFunction · 0.85
FCEU_LuaGuiFunction · 0.85
ReallySnapFunction · 0.85
FCEUI_EmulationPausedFunction · 0.85
DrawMessageFunction · 0.85
snapAVIFunction · 0.85
FCEU_VSUniDrawFunction · 0.85
FCEU_DrawSaveStatesFunction · 0.85
FCEU_DrawMoviesFunction · 0.85

Tested by

no test coverage detected