diff options
| author | 2019-02-03 04:58:01 -0300 | |
|---|---|---|
| committer | 2019-02-03 04:58:40 -0300 | |
| commit | 04e68e973829ddfb262f0539627ec7fe56424fb2 (patch) | |
| tree | c60e622554a06d2ff0accd60260f498f785b3210 /src | |
| parent | maxwell_3d: Allow texture handles with TIC id zero (diff) | |
| download | yuzu-04e68e973829ddfb262f0539627ec7fe56424fb2.tar.gz yuzu-04e68e973829ddfb262f0539627ec7fe56424fb2.tar.xz yuzu-04e68e973829ddfb262f0539627ec7fe56424fb2.zip | |
maxwell_3d: Allow sampler handles with TSC id zero
Diffstat (limited to 'src')
| -rw-r--r-- | src/video_core/engines/maxwell_3d.cpp | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/src/video_core/engines/maxwell_3d.cpp b/src/video_core/engines/maxwell_3d.cpp index cda9b0da5..2cd6d6094 100644 --- a/src/video_core/engines/maxwell_3d.cpp +++ b/src/video_core/engines/maxwell_3d.cpp | |||
| @@ -467,11 +467,9 @@ std::vector<Texture::FullTextureInfo> Maxwell3D::GetStageTextures(Regs::ShaderSt | |||
| 467 | std::memcpy(&tex_info.tic, &tic_entry, sizeof(tic_entry)); | 467 | std::memcpy(&tex_info.tic, &tic_entry, sizeof(tic_entry)); |
| 468 | 468 | ||
| 469 | // Load the TSC data | 469 | // Load the TSC data |
| 470 | if (tex_handle.tsc_id != 0) { | 470 | auto tsc_entry = GetTSCEntry(tex_handle.tsc_id); |
| 471 | auto tsc_entry = GetTSCEntry(tex_handle.tsc_id); | 471 | // TODO(Subv): Workaround for BitField's move constructor being deleted. |
| 472 | // TODO(Subv): Workaround for BitField's move constructor being deleted. | 472 | std::memcpy(&tex_info.tsc, &tsc_entry, sizeof(tsc_entry)); |
| 473 | std::memcpy(&tex_info.tsc, &tsc_entry, sizeof(tsc_entry)); | ||
| 474 | } | ||
| 475 | 473 | ||
| 476 | textures.push_back(tex_info); | 474 | textures.push_back(tex_info); |
| 477 | } | 475 | } |
| @@ -501,11 +499,9 @@ Texture::FullTextureInfo Maxwell3D::GetStageTexture(Regs::ShaderStage stage, | |||
| 501 | std::memcpy(&tex_info.tic, &tic_entry, sizeof(tic_entry)); | 499 | std::memcpy(&tex_info.tic, &tic_entry, sizeof(tic_entry)); |
| 502 | 500 | ||
| 503 | // Load the TSC data | 501 | // Load the TSC data |
| 504 | if (tex_handle.tsc_id != 0) { | 502 | auto tsc_entry = GetTSCEntry(tex_handle.tsc_id); |
| 505 | auto tsc_entry = GetTSCEntry(tex_handle.tsc_id); | 503 | // TODO(Subv): Workaround for BitField's move constructor being deleted. |
| 506 | // TODO(Subv): Workaround for BitField's move constructor being deleted. | 504 | std::memcpy(&tex_info.tsc, &tsc_entry, sizeof(tsc_entry)); |
| 507 | std::memcpy(&tex_info.tsc, &tsc_entry, sizeof(tsc_entry)); | ||
| 508 | } | ||
| 509 | 505 | ||
| 510 | return tex_info; | 506 | return tex_info; |
| 511 | } | 507 | } |