Fixes for PGO
This commit is contained in:
parent
da0ef0e902
commit
8095b25905
3 changed files with 13 additions and 8 deletions
|
@ -198,7 +198,9 @@ void VideoDecoder::DecodeThread()
|
|||
}
|
||||
|
||||
DecodeFrame();
|
||||
_renderer->UpdateFrame(_frameBuffer);
|
||||
if(_renderer) {
|
||||
_renderer->UpdateFrame(_frameBuffer);
|
||||
}
|
||||
|
||||
_waitForRender.Signal();
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@ class VideoDecoder
|
|||
private:
|
||||
static unique_ptr<VideoDecoder> Instance;
|
||||
|
||||
IRenderingDevice* _renderer;
|
||||
IRenderingDevice* _renderer = nullptr;
|
||||
|
||||
uint16_t *_ppuOutputBuffer = nullptr;
|
||||
HdPpuPixelInfo *_hdScreenTiles = nullptr;
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
#include <iostream>
|
||||
#include <thread>
|
||||
#include <vector>
|
||||
#include <string>
|
||||
|
@ -13,19 +14,21 @@ int main(int argc, char* argv[])
|
|||
{
|
||||
using namespace std;
|
||||
vector<char*> testRoms{
|
||||
"..\\Games\\Super Dodge Ball (USA).nes",
|
||||
"..\\Games\\Super Mario Bros. (USA).nes",
|
||||
"..\\Games\\Mega Man 2 (USA).nes",
|
||||
"..\\Games\\Mega Man 3 (USA).nes",
|
||||
"..\\Games\\Mega Man 4 (USA).nes",
|
||||
"..\\Games\\MMC5\\Just Breed (J) [!].nes"
|
||||
"..\\..\\Games\\Super Dodge Ball (USA).nes",
|
||||
"..\\..\\Games\\Super Mario Bros. (USA).nes",
|
||||
"..\\..\\Games\\Mega Man 2 (USA).nes",
|
||||
"..\\..\\Games\\Mega Man 3 (USA).nes",
|
||||
"..\\..\\Games\\Mega Man 4 (USA).nes",
|
||||
"..\\..\\Games\\MMC5\\Just Breed (J) [!].nes"
|
||||
};
|
||||
|
||||
InitializeEmu("C:\\Windows\\Temp\\Mesen", nullptr, nullptr);
|
||||
LoadROM(testRoms[0]);
|
||||
std::cout << "Running: " << testRoms[0] << std::endl;
|
||||
thread testThread([testRoms] {
|
||||
for(size_t i = 1; i < testRoms.size(); i++) {
|
||||
std::this_thread::sleep_for(std::chrono::duration<int, std::milli>(5000));
|
||||
std::cout << "Running: " << testRoms[i] << std::endl;
|
||||
LoadROM(testRoms[i]);
|
||||
}
|
||||
Stop();
|
||||
|
|
Loading…
Add table
Reference in a new issue