diff options
Diffstat (limited to 'servers/xr/xr_interface.cpp')
-rw-r--r-- | servers/xr/xr_interface.cpp | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/servers/xr/xr_interface.cpp b/servers/xr/xr_interface.cpp index 430e2042d9..a5ee1d5726 100644 --- a/servers/xr/xr_interface.cpp +++ b/servers/xr/xr_interface.cpp @@ -222,12 +222,7 @@ RID XRInterface::get_vrs_texture() { data_ptr[d++] = density; } } - - Ref<Image> image; - image.instantiate(); - image->create_from_data(vrs_sizei.x, vrs_sizei.y, false, Image::FORMAT_R8, data); - - images.push_back(image); + images.push_back(Image::create_from_data(vrs_sizei.x, vrs_sizei.y, false, Image::FORMAT_R8, data)); } if (images.size() == 1) { |