prevent buffer view from crashing

This commit is contained in:
Samuliak 2024-10-05 14:11:58 +02:00
parent 1b690aab26
commit 08dbc9bd8d
No known key found for this signature in database
2 changed files with 2 additions and 2 deletions

View file

@ -27,7 +27,7 @@ BufferView::BufferView(MTL::Buffer* buffer_, size_t offset_, size_t size_,
: buffer{buffer_->retain()}, offset{offset_}, size{size_}, format{format_} {}
BufferView::~BufferView() {
buffer->release();
// buffer->release();
}
Buffer::Buffer(BufferCacheRuntime& runtime, VideoCommon::NullBufferParams null_params)

View file

@ -22,7 +22,7 @@ struct BufferView {
VideoCore::Surface::PixelFormat format_ = VideoCore::Surface::PixelFormat::Invalid);
~BufferView();
MTL::Buffer* buffer = nil;
MTL::Buffer* buffer = nullptr;
size_t offset{};
size_t size{};
VideoCore::Surface::PixelFormat format{};