diff options
author | Ibrahn Sahir <ibrahn.sahir@gmail.com> | 2019-07-05 18:08:43 +0100 |
---|---|---|
committer | Ibrahn Sahir <ibrahn.sahir@gmail.com> | 2019-07-06 12:04:27 +0100 |
commit | 4e4697b1c481094949165fa9edbe6aeebcfcf3b4 (patch) | |
tree | a05fa9e7249febb9093885ddc21da1cd967be314 /drivers/gles2 | |
parent | 0b6b49a897b35bec53765e1288c32d57afa1a293 (diff) |
Added release function to PoolVector::Access.
For clarity, assign-to-release idiom for PoolVector::Read/Write
replaced with a function call.
Existing uses replaced (or removed if already handled by scope)
Diffstat (limited to 'drivers/gles2')
-rw-r--r-- | drivers/gles2/rasterizer_storage_gles2.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/gles2/rasterizer_storage_gles2.cpp b/drivers/gles2/rasterizer_storage_gles2.cpp index b08202ae45..c591db4f3d 100644 --- a/drivers/gles2/rasterizer_storage_gles2.cpp +++ b/drivers/gles2/rasterizer_storage_gles2.cpp @@ -807,7 +807,7 @@ Ref<Image> RasterizerStorageGLES2::texture_get_data(RID p_texture, int p_layer) } } - wb = PoolVector<uint8_t>::Write(); + wb.release(); data.resize(data_size); @@ -871,7 +871,7 @@ Ref<Image> RasterizerStorageGLES2::texture_get_data(RID p_texture, int p_layer) glBindFramebuffer(GL_FRAMEBUFFER, 0); glDeleteFramebuffers(1, &temp_framebuffer); - wb = PoolVector<uint8_t>::Write(); + wb.release(); data.resize(data_size); @@ -2155,8 +2155,8 @@ static PoolVector<uint8_t> _unpack_half_floats(const PoolVector<uint8_t> &array, dst_offset += dst_size[i]; } - r = PoolVector<uint8_t>::Read(); - w = PoolVector<uint8_t>::Write(); + r.release(); + w.release(); return ret; } |