mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-11-22 06:42:46 +01:00
prevent buffer view from crashing
This commit is contained in:
parent
1b690aab26
commit
08dbc9bd8d
2 changed files with 2 additions and 2 deletions
|
@ -27,7 +27,7 @@ BufferView::BufferView(MTL::Buffer* buffer_, size_t offset_, size_t size_,
|
||||||
: buffer{buffer_->retain()}, offset{offset_}, size{size_}, format{format_} {}
|
: buffer{buffer_->retain()}, offset{offset_}, size{size_}, format{format_} {}
|
||||||
|
|
||||||
BufferView::~BufferView() {
|
BufferView::~BufferView() {
|
||||||
buffer->release();
|
// buffer->release();
|
||||||
}
|
}
|
||||||
|
|
||||||
Buffer::Buffer(BufferCacheRuntime& runtime, VideoCommon::NullBufferParams null_params)
|
Buffer::Buffer(BufferCacheRuntime& runtime, VideoCommon::NullBufferParams null_params)
|
||||||
|
|
|
@ -22,7 +22,7 @@ struct BufferView {
|
||||||
VideoCore::Surface::PixelFormat format_ = VideoCore::Surface::PixelFormat::Invalid);
|
VideoCore::Surface::PixelFormat format_ = VideoCore::Surface::PixelFormat::Invalid);
|
||||||
~BufferView();
|
~BufferView();
|
||||||
|
|
||||||
MTL::Buffer* buffer = nil;
|
MTL::Buffer* buffer = nullptr;
|
||||||
size_t offset{};
|
size_t offset{};
|
||||||
size_t size{};
|
size_t size{};
|
||||||
VideoCore::Surface::PixelFormat format{};
|
VideoCore::Surface::PixelFormat format{};
|
||||||
|
|
Loading…
Reference in a new issue