dolphin icon indicating copy to clipboard operation
dolphin copied to clipboard

BitFieldView: Video Changes

Open Minty-Meeo opened this issue 2 years ago • 4 comments

This PR is part 2 of splitting the monolithic PR #10610. It is dependent on PR #10846.

Minty-Meeo avatar Jul 14 '22 19:07 Minty-Meeo

This pull request increments GX_PIPELINE_UID_VERSION (GXPipelineTypes.h) and STATE_VERSION (State.cpp).

Minty-Meeo avatar Jul 14 '22 20:07 Minty-Meeo

What a headache that rebase was.

Minty-Meeo avatar Aug 27 '22 04:08 Minty-Meeo

FifoCI detected that this change impacts graphical rendering. Here are the behavior differences detected by the system:

  • burnout2-vehicletextures on ogl-lin-radeon: diff
  • custom-brawl-char on ogl-lin-radeon: diff
  • fishing-resort-map on ogl-lin-radeon: diff
  • fortune-street on ogl-lin-radeon: diff
  • fortune-street-fog on ogl-lin-radeon: diff
  • f-zero-rain on ogl-lin-radeon: diff
  • mini-ninjas on ogl-lin-radeon: diff
  • mkdd-efb on ogl-lin-radeon: diff
  • nddemo-lighting on ogl-lin-radeon: diff
  • pbr-sfx on ogl-lin-radeon: diff
  • rs2-skybox on ogl-lin-radeon: diff
  • sadx-ui on ogl-lin-radeon: diff
  • sfa-shadows on ogl-lin-radeon: diff
  • sf-assault-flashing on ogl-lin-radeon: diff
  • soa-black on ogl-lin-radeon: diff
  • sonic-riders-blur on ogl-lin-radeon: diff
  • sonic-riders-zg-4p on ogl-lin-radeon: diff
  • sonicriderszg-gb on ogl-lin-radeon: diff
  • spyro-bloom on ogl-lin-radeon: diff
  • spyro-depth on ogl-lin-radeon: diff
  • ssbb-mod-lloyd on ogl-lin-radeon: diff
  • sw3-dt on ogl-lin-radeon: diff
  • tla-menu on ogl-lin-radeon: diff
  • tp-skin on ogl-lin-radeon: diff
  • tsp3-pinkgrass on ogl-lin-radeon: diff
  • vegas-party-depth on ogl-lin-radeon: diff
  • xenoblade-menu on ogl-lin-radeon: diff
  • ztp-grass on ogl-lin-radeon: diff
  • zww-armos on ogl-lin-radeon: diff
  • zww-water on ogl-lin-radeon: diff
  • zww-waves on ogl-lin-radeon: diff

automated-fifoci-reporter

dolphin-emu-bot avatar Aug 27 '22 04:08 dolphin-emu-bot

And that is why I made a backup

Minty-Meeo avatar Aug 27 '22 04:08 Minty-Meeo

Do not be alarmed by the force push. I decided to remake this goliath of a PR to both further split it into commits and also because rebasing proved difficult. I have a backup of the original changes on branch bfview-video-copy which I will be referencing throughout the process.

Minty-Meeo avatar Oct 12 '22 08:10 Minty-Meeo

I found conflicting info on whether a TexInputForm field is supposed to be two bits or one bit wide. I think the info in XFMemory.h strongly suggests the latter.

Minty-Meeo avatar Oct 13 '22 05:10 Minty-Meeo

I am thinking the cc and ac 24-bit values in the PixelShader UID's stagehashes might be better off as C bit fields. I really want to make them into C23's BitInts or some kind of native int24_t, and a C bit field is the next best thing.

Minty-Meeo avatar Oct 13 '22 17:10 Minty-Meeo

I've wanted to make the usage of the component field cleaner, but I think the code might end up less efficient. Before, it would be right shift by constant (since it is zero, this is a no-op), mask by constant, mask by constant, compare against 0 (two operations, after the two masks get fused). Now it is right shift by constant, mask by constant, compare against 0 (three operations).

Minty-Meeo avatar Oct 13 '22 22:10 Minty-Meeo

Well I thought I was clever in optimizing Common::ExtractBit to use the same idiom as seen in VertexShaderGen, only to see the compiler do this: https://godbolt.org/z/evjr8hrrx.

Minty-Meeo avatar Oct 14 '22 06:10 Minty-Meeo