[PR #3055] [MERGED] shader_recompiler: Implement linear interpolation support #3182

Closed
opened 2026-02-27 22:02:45 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/shadps4-emu/shadPS4/pull/3055
Author: @raphaelthegreat
Created: 6/8/2025
Status: Merged
Merged: 6/8/2025
Merged by: @georgemoralis

Base: mainHead: linear-interp


📝 Commits (1)

  • c947811 shader_recompiler: Implement linear interpolation support

📊 Changes

14 files changed (+421 additions, -371 deletions)

View changed files

📝 src/shader_recompiler/backend/spirv/spirv_emit_context.cpp (+17 -6)
📝 src/shader_recompiler/backend/spirv/spirv_emit_context.h (+2 -2)
📝 src/shader_recompiler/frontend/structured_control_flow.cpp (+7 -5)
📝 src/shader_recompiler/frontend/translate/translate.cpp (+72 -61)
📝 src/shader_recompiler/frontend/translate/translate.h (+10 -6)
📝 src/shader_recompiler/frontend/translate/vector_interpolation.cpp (+3 -2)
📝 src/shader_recompiler/info.h (+4 -0)
📝 src/shader_recompiler/ir/attribute.h (+19 -0)
📝 src/shader_recompiler/ir/ir_emitter.cpp (+0 -1)
📝 src/shader_recompiler/ir/ir_emitter.h (+1 -1)
📝 src/shader_recompiler/ir/reg.h (+1 -1)
📝 src/video_core/amdgpu/pixel_format.h (+285 -9)
📝 src/video_core/amdgpu/resource.h (+0 -1)
📝 src/video_core/amdgpu/types.h (+0 -276)

📄 Description

This is used by Driveclub (CUSA00093) for some light passes. Fixes the warp effect in the edges of the screen during nighttime races and a "haze" effect inside the car

Note: Technically this isn't fully accurate as it doesn't handle Sample and Centroid. This can be remedied by using VK_AMD_shader_explicit_vertex_parameter but that would add complexity that isnt needed here so it wasn't done


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/shadps4-emu/shadPS4/pull/3055 **Author:** [@raphaelthegreat](https://github.com/raphaelthegreat) **Created:** 6/8/2025 **Status:** ✅ Merged **Merged:** 6/8/2025 **Merged by:** [@georgemoralis](https://github.com/georgemoralis) **Base:** `main` ← **Head:** `linear-interp` --- ### 📝 Commits (1) - [`c947811`](https://github.com/shadps4-emu/shadPS4/commit/c947811616f7ac72a529a8911997dced01fcccf0) shader_recompiler: Implement linear interpolation support ### 📊 Changes **14 files changed** (+421 additions, -371 deletions) <details> <summary>View changed files</summary> 📝 `src/shader_recompiler/backend/spirv/spirv_emit_context.cpp` (+17 -6) 📝 `src/shader_recompiler/backend/spirv/spirv_emit_context.h` (+2 -2) 📝 `src/shader_recompiler/frontend/structured_control_flow.cpp` (+7 -5) 📝 `src/shader_recompiler/frontend/translate/translate.cpp` (+72 -61) 📝 `src/shader_recompiler/frontend/translate/translate.h` (+10 -6) 📝 `src/shader_recompiler/frontend/translate/vector_interpolation.cpp` (+3 -2) 📝 `src/shader_recompiler/info.h` (+4 -0) 📝 `src/shader_recompiler/ir/attribute.h` (+19 -0) 📝 `src/shader_recompiler/ir/ir_emitter.cpp` (+0 -1) 📝 `src/shader_recompiler/ir/ir_emitter.h` (+1 -1) 📝 `src/shader_recompiler/ir/reg.h` (+1 -1) 📝 `src/video_core/amdgpu/pixel_format.h` (+285 -9) 📝 `src/video_core/amdgpu/resource.h` (+0 -1) 📝 `src/video_core/amdgpu/types.h` (+0 -276) </details> ### 📄 Description This is used by Driveclub (CUSA00093) for some light passes. Fixes the warp effect in the edges of the screen during nighttime races and a "haze" effect inside the car Note: Technically this isn't fully accurate as it doesn't handle Sample and Centroid. This can be remedied by using VK_AMD_shader_explicit_vertex_parameter but that would add complexity that isnt needed here so it wasn't done --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-27 22:02:45 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/shadPS4#3182
No description provided.