diff options
| author | Pierre Bourdon <delroth@gmail.com> | 2016-01-09 01:01:05 +0100 |
|---|---|---|
| committer | Pierre Bourdon <delroth@gmail.com> | 2016-01-09 01:01:05 +0100 |
| commit | bf1c53a6e8f18d45682af7a16d17b1173536254b (patch) | |
| tree | ecfc3fe7522b175cba68dca3fb0eeea3a90d4668 /Source/Core/VideoCommon/RenderBase.cpp | |
| parent | b56a084b0b04cd5e229eefb069579325a2095d3a (diff) | |
| parent | 66595b0ac98cea09c249202aa8bcde78f434808a (diff) | |
Merge pull request #3451 from RisingFog/libav
Use ffmpeg for Windows Video Dumping instead of VFW
Diffstat (limited to 'Source/Core/VideoCommon/RenderBase.cpp')
| -rw-r--r-- | Source/Core/VideoCommon/RenderBase.cpp | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/Source/Core/VideoCommon/RenderBase.cpp b/Source/Core/VideoCommon/RenderBase.cpp index c52263843f..5054fd61d5 100644 --- a/Source/Core/VideoCommon/RenderBase.cpp +++ b/Source/Core/VideoCommon/RenderBase.cpp @@ -102,13 +102,9 @@ Renderer::~Renderer() prev_efb_format = PEControl::INVALID_FMT; efb_scale_numeratorX = efb_scale_numeratorY = efb_scale_denominatorX = efb_scale_denominatorY = 1; - #if defined _WIN32 || defined HAVE_LIBAV if (SConfig::GetInstance().m_DumpFrames && bLastFrameDumped && bAVIDumping) AVIDump::Stop(); -#else - if (pFrameDump.IsOpen()) - pFrameDump.Close(); #endif } @@ -617,3 +613,15 @@ void Renderer::Swap(u32 xfbAddr, u32 fbWidth, u32 fbStride, u32 fbHeight, const XFBWrited = false; } +void Renderer::FlipImageData(u8* data, int w, int h, int pixel_width) +{ + for (int y = 0; y < h / 2; ++y) + { + for (int x = 0; x < w; ++x) + { + for (int delta = 0; delta < pixel_width; ++delta) + std::swap(data[(y * w + x) * pixel_width + delta], data[((h - 1 - y) * w + x) * pixel_width + delta]); + } + } +} + |
