1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-06 12:20:30 +00:00

Don't crash on previewing an AtlasTexture without a region

This commit is contained in:
Hein-Pieter van Braam
2019-02-27 00:44:09 +00:00
parent 270bbee018
commit 464e1142c4
2 changed files with 8 additions and 0 deletions

View File

@@ -426,6 +426,8 @@ ImageTexture::ImageTexture() {
texture = VisualServer::get_singleton()->texture_create();
storage = STORAGE_RAW;
lossy_storage_quality = 0.7;
image_stored = false;
format = Image::Format::FORMAT_L8;
}
ImageTexture::~ImageTexture() {
@@ -1514,6 +1516,7 @@ CubeMap::CubeMap() {
cubemap = VisualServer::get_singleton()->texture_create();
storage = STORAGE_RAW;
lossy_storage_quality = 0.7;
format = Image::Format::FORMAT_BPTC_RGBA;
}
CubeMap::~CubeMap() {