mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-12-01 01:11:46 +00:00
Merge pull request #16354 from hrydgard/vulkan-input-attachment-fix
Vulkan: Use the very same view as input attachment and color attachment, not just the same image
This commit is contained in:
commit
c6116581b6
@ -42,6 +42,12 @@ VKAPI_ATTR VkBool32 VKAPI_CALL VulkanDebugUtilsCallback(
|
||||
// UNASSIGNED
|
||||
return false;
|
||||
}
|
||||
if (messageCode == 606910136 || messageCode == -392708513) {
|
||||
// VUID-vkCmdDraw-None-02686
|
||||
// Kinda false positive, or at least very unnecessary, now that I solved the real issue.
|
||||
// See https://github.com/hrydgard/ppsspp/pull/16354
|
||||
return false;
|
||||
}
|
||||
|
||||
if (messageSeverity & VK_DEBUG_UTILS_MESSAGE_SEVERITY_ERROR_BIT_EXT) {
|
||||
message << "ERROR(";
|
||||
|
@ -1703,11 +1703,8 @@ uint64_t VKContext::GetNativeObject(NativeObject obj, void *srcObject) {
|
||||
return (uint64_t)(((VKTexture *)srcObject)->GetImageView());
|
||||
case NativeObject::BOUND_FRAMEBUFFER_COLOR_IMAGEVIEW_ALL_LAYERS:
|
||||
return (uint64_t)curFramebuffer_->GetFB()->color.texAllLayersView;
|
||||
case NativeObject::BOUND_FRAMEBUFFER_COLOR_IMAGEVIEW_LAYER: {
|
||||
size_t layer = (size_t)srcObject;
|
||||
_dbg_assert_(layer < curFramebuffer_->Layers());
|
||||
return (uint64_t)curFramebuffer_->GetFB()->color.texLayerViews[layer];
|
||||
}
|
||||
case NativeObject::BOUND_FRAMEBUFFER_COLOR_IMAGEVIEW_RT:
|
||||
return (uint64_t)curFramebuffer_->GetFB()->color.rtView;
|
||||
case NativeObject::FRAME_DATA_DESC_SET_LAYOUT:
|
||||
return (uint64_t)frameDescSetLayout_;
|
||||
case NativeObject::THIN3D_PIPELINE_LAYOUT:
|
||||
|
@ -245,7 +245,7 @@ enum class NativeObject {
|
||||
BOUND_TEXTURE0_IMAGEVIEW, // Layer etc depends on how you bound it...
|
||||
BOUND_TEXTURE1_IMAGEVIEW, // Layer etc depends on how you bound it...
|
||||
BOUND_FRAMEBUFFER_COLOR_IMAGEVIEW_ALL_LAYERS,
|
||||
BOUND_FRAMEBUFFER_COLOR_IMAGEVIEW_LAYER, // use an int cast to void *srcObject to specify layer.
|
||||
BOUND_FRAMEBUFFER_COLOR_IMAGEVIEW_RT,
|
||||
RENDER_MANAGER,
|
||||
TEXTURE_VIEW,
|
||||
NULL_IMAGEVIEW,
|
||||
|
@ -377,10 +377,11 @@ void DrawEngineVulkan::BindShaderBlendTex() {
|
||||
dirtyRequiresRecheck_ |= DIRTY_BLEND_STATE;
|
||||
} else if (fboTexBindState_ == FBO_TEX_READ_FRAMEBUFFER) {
|
||||
draw_->BindCurrentFramebufferForColorInput();
|
||||
boundSecondary_ = (VkImageView)draw_->GetNativeObject(Draw::NativeObject::BOUND_FRAMEBUFFER_COLOR_IMAGEVIEW_LAYER, (void *)0);
|
||||
boundSecondary_ = (VkImageView)draw_->GetNativeObject(Draw::NativeObject::BOUND_FRAMEBUFFER_COLOR_IMAGEVIEW_RT, (void *)0);
|
||||
boundSecondaryIsInputAttachment_ = true;
|
||||
fboTexBindState_ = FBO_TEX_NONE;
|
||||
} else {
|
||||
boundSecondaryIsInputAttachment_ = false;
|
||||
boundSecondary_ = VK_NULL_HANDLE;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user