Skip to content

Commit c5ade27

Browse files
fix more silly typos, add default callbacks to ISimpleManagedSurface
1 parent 5942569 commit c5ade27

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

include/nbl/video/utilities/ISimpleManagedSurface.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -147,11 +147,11 @@ class NBL_API2 ISimpleManagedSurface : public core::IReferenceCounted
147147
swapchain = nullptr;
148148
}
149149

150-
// here you drop your own resources of the base class
151-
virtual void invalidate_impl() = 0;
150+
// Here you drop your own resources of the base class
151+
virtual void invalidate_impl() {}
152152

153-
// extra things you might need
154-
virtual bool onCreateSwapchain_impl(const uint8_t qFam) = 0;
153+
// For creating extra per-image or swapchain resources you might need
154+
virtual bool onCreateSwapchain_impl(const uint8_t qFam) {return true;}
155155

156156
// We start with a `nullptr` swapchain because some implementations might defer its creation
157157
core::smart_refctd_ptr<ISwapchain> swapchain = {};

src/nbl/video/IGPUCommandBuffer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1273,7 +1273,7 @@ bool IGPUCommandBuffer::blitImage(const IGPUImage* const srcImage, const IGPUIma
12731273
return false;
12741274

12751275
const auto& dstParams = dstImage->getCreationParameters();
1276-
if (!dstImage || !this->isCompatibleDevicewise(dstImage) || !dstParams.usage.hasFlags(IGPUImage::EUF_TRANSFER_SRC_BIT) || !physDev->getImageFormatUsages(dstImage->getTiling())[dstParams.format].blitDst)
1276+
if (!dstImage || !this->isCompatibleDevicewise(dstImage) || !dstParams.usage.hasFlags(IGPUImage::EUF_TRANSFER_DST_BIT) || !physDev->getImageFormatUsages(dstImage->getTiling())[dstParams.format].blitDst)
12771277
return false;
12781278

12791279
// TODO rest of: https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/vkCmdBlitImage.html#VUID-vkCmdBlitImage-srcImage-00229

0 commit comments

Comments
 (0)