summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/Present.cpp
AgeCommit message (Collapse)Author
2026-01-17Fix various typos and spelling mistakesSintendo
2025-11-25VideoCommon: Add a hidden setting to cap immediate XFB swaps to one per VI.Jordan Woyak
2025-11-11VideoCommon: Add "Smooth Early Presentation" setting to improve frame pacing ↵Jordan Woyak
with ImmediateXFB and/or RushFramePresentation.
2025-11-11VideoCommon: Make Presenter aware of the next swap time to eliminate unsafe ↵Jordan Woyak
usage of GetTicks() with ImmediateXFB + DualCore.
2025-11-11CoreTiming: Add "Rush Frame Presentation" setting to throttle only once ↵Jordan Woyak
after each presentation for lower input latency.
2025-11-11Merge pull request #14071 from iwubcode/avoid_config_framebuffer_managerJMC47
VideoCommon: pass the EFB buffer scale into the FramebufferManager
2025-11-06Common: Remove the string parameters from the HookableEvent interface.Jordan Woyak
2025-11-05VideoCommon: pass the EFB buffer scale into the FramebufferManager instead ↵iwubcode
of pulling it from config, in the future this will allow us to have multiple framebuffers
2025-11-02Common: Make HookableEvent use non-static data.Jordan Woyak
Co-authored-by: Dentomologist <dentomologist@gmail.com>
2025-03-16VideoConfig: Eliminate frame dumping members.Jordan Woyak
2025-03-10Core/VideoCommon: Push presentation time calculated from CPU thread to GPU ↵Jordan Woyak
thread.
2025-03-09VideoCommon: Move backend_info out of VideoConfig struct.Jordan Woyak
2024-10-02VideoBackends:Vulkan: Don't try to present if swapchain acquire failedTellowKrinkle
2024-08-22Graphics: Adapt aspect ratio when SBS/TAB 3D is usedBryan Jacobs
Adds support for choosing to present the full resolution independently to each eye when using side-by-side or top-and-bottom 3D.
2024-04-18Merge pull request #12698 from iwubcode/xfb_copy_hash_in_presentAdmiral H. Curtiss
VideoCommon: add xfbs hashes to present info if available
2024-04-13VideoConfig: Adjust FrameDumpResolutionType enum class to style guidelinesAdmiral H. Curtiss
2024-04-09VideoCommon: add xfb hash values (if available) to present informationiwubcode
2024-04-08Video: remove enforced resolution least common multiple of 4 when dumping ↵Filoppi
screenshots and not videos (only videos encoders have this limit). NOTE: this will likely trigger FIFOCI differences.
2024-04-08Video: split frame dumping settings into 3 resolution dumping modesFiloppi
also polish aspect ratio related code for clarity
2024-04-03Video: move all padding added for frame dumping to a single function,Filoppi
which also avoids the output window from being resized randomly to be a multiple of 4
2024-04-03Video: Change the frame dumper to actually use the raw emulation output ↵Filoppi
resolution, avoiding any scaling if possible. This should make comparisons much more reliable as pixels wouldn't be smushed together or stretched.
2024-02-29Add custom relative and raw (squared pixels) aspect ratio modesFiloppi
2024-02-20Video: Make the game resolution (within the window) snap to the XFB size if ↵Filoppi
they are within a ~1 pixel treshold on one axis only. This takes care of making the image clearer in some edge cases where the game was already running at near perfect 4:3 with no stretching, and the VI aspect ratio didn't match the XFB by one pixel, making the image stretched and blurry. -Video: Fix `FindClosestIntegerResolution() using the window aspect ratio and not the draw aspect ratio, causing it to prefer stretching over black bars in cases when it wasn't desirable.
2024-01-31VideoCommon/Statistics: Remove global system accessor from s_after_frame_eventLioncash
Instead, we make the event take a reference to the system and then pass it in when the event is triggered. This does introduce two other accessors, but these are much easier to refactor out over time, and without modification to the existing event interface.
2023-12-18Video: make the "Auto" resolution setting also follow the max res setting, ↵Filoppi
to avoid trying to create texture bigger than the maximum supported one
2023-12-18Video: fix auto resolution scale calculationsFiloppi
2023-12-18Video: fix Auto Resolution Scale not updating when the window was resized.Filoppi
Also fixes the widescreen hack not fully updating when the aspect ratio setting changed on the spot.
2023-12-18Video: implement custom aspect ratio support (already exposed to Qt).Filoppi
This also renamed some variables/functions.
2023-12-18Video: rename Presenter::SetWindowSize()Filoppi
2023-12-09VideoCommon/Present: Remove use of g_presenter inside Presenter classLioncash
There's no need to self reference a global of the class itself when we can just call the function directly.
2023-10-25VideoCommon: Don't swap on state load when there's no XFB.Admiral H. Curtiss
This triggers an assert in TCacheEntry::SetXfbCopy() otherwise if you load a savestate that was made before the first XFB has been rendered.
2023-08-18Video: The `Auto` internal resolution scaling wasn't working correctly if ↵Filoppi
the window weird aspect ratios (e.g. 32:9), beacuse it would account for the the portion of the image that will show black bars into the calcuations to find the best matching resolution
2023-08-18Video: The `Auto-Adjust Window Size` setting was calculating the window size ↵Filoppi
based on the resolution of the window in the previous frame if we used the "stretch" aspect ratio setting, so it's result would be self influence in a loop and behave unreliably (e.g. when changing resolution between Auto/Native/2x the automatic window scaling would behave randomly)
2023-08-18Video: There was always a black line around one of the 4 edges ↵Filoppi
(top/left/bottom/right) of the window because the final output size wasn't calculated right (unless the aspect ratio was set to stretch)
2023-08-18Video: The `% 4` that was done on the rendering resolution was only meant to ↵Filoppi
be done when recording videos (due to encoding limitations) but one case was missed (this had no consequences really, as it was just in the code that automatically resizes the window). The hardcoded `4` has been replaced with `VIDEO_ENCODER_LMC` for clarity.
2023-06-19Video: implement color correction to match the NTSC and PAL color spaces ↵Filoppi
(and gamma) that GC and Wii targeted. To further increase the accuracy of the post process phase, I've added (scRGB) HDR support, which is necessary to fully display the PAL and NTSC-J color spaces, and also to improve the quality of post process texture samplings and do them in linear space instead of gamma space (which is very important when playing at low resolutions). For SDR, the quality is also slightly increased, at least if any post process runs, as the buffer is now R10G10B10A2 (on Vulkan, DX11 and DX12) if supported; previously it was R8G8B8A8 but the alpha bits were wasted. Gamma correction is arguably the most important thing as Dolphin on Windows outputted in "sRGB" (implicitly) as that's what Windows expects by default, though sRGB gamma is very different from the gamma commonly used by video standards dating to the pre HDR era (roughly gamma 2.35). Additionally, the addition of HDR support (which is pretty straight forward and minimal), added support for our own custom AutoHDR shaders, which would allow us to achieve decent looking HDR in Dolphin games without having to use SpecialK or Windows 11 AutoHDR. Both of which don't necessarily play nice with older games with strongly different and simpler lighting. HDR should also be supported in Linux. Development of my own AutoHDR shader is almost complete and will come next. This has been carefully tested and there should be no regression in any of the different features that Dolphin offers, like multisampling, stereo rendering, other post processes, etc etc. Fixes: https://bugs.dolphin-emu.org/issues/8941 Co-authored-by: EndlesslyFlowering <EndlesslyFlowering@protonmail.com> Co-authored-by: Dogway <lin_ares@hotmail.com>
2023-06-17Merge pull request #11918 from TellowKrinkle/DPIScaleAdmiral H. Curtiss
Improved DPI change handling
2023-06-11VideoCommon: Update imgui scale when dpi changesTellowKrinkle
2023-06-04Fix video output having small black borders all the timesFilippo Tarpini
To maintain compatibility with some video encoders, the whole output buffer was scaled to be a multiple of 4. This change makes it so that that rule only applies while actively recording (or taking screenshots, even if it might not be necessary for that case).
2023-03-11HW/VideoInterface: Refactor to class.Admiral H. Curtiss
2023-03-02Software: Fix "Auto-Adjust Window Size"Pokechu22
This also needs to be handled on the software renderer path.
2023-03-02Software: Fix crash on startup when using "Compile Shaders Before Starting"Pokechu22
When that setting is enabled, m_xfb_entry is initially not present (during the phase where a shader compilation progress bar would be shown). The main path checks for m_xfb_entry, but the software renderer fallback path didn't. Fixes another aspect of https://bugs.dolphin-emu.org/issues/13172.
2023-02-09Hook up Presenter's ConfigChanged functionScott Mansell
Fixes issue with post-processing not working
2023-02-09Insert a more solid abstraction between Qt and ImguiScott Mansell
2023-02-09Presenter: Handle blanked frames correctlyScott Mansell
2023-02-09Fix XFB duplicate detectionScott Mansell
Frame duplicate detection was inverted. Huge problem for 60fps games where it would see all frames as "duplicates" and nothing would ever be presented.
2023-02-09Move WidescreenHeuristic to it's own classScott Mansell
It's about the only thing left in renderer
2023-02-09Lint fixesScott Mansell
2023-02-09Move xfb tracking and IR scaling out of RenderBaseScott Mansell
2023-01-31Expose Renderer's FramecountScott Mansell
We don't want to move it, because we want to complete this refactor without changing savestate version