mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2024-12-24 04:46:48 +01:00
Use ERR_FAIL_COND macro again if the image passed in is not valid in index_image. Also don't delete color information.
This commit is contained in:
parent
53aed73a64
commit
dcdb5715cc
@ -6,11 +6,8 @@ PoolColorArray ImageIndexer::get_colors() {
|
||||
}
|
||||
|
||||
PoolIntArray ImageIndexer::index_image(Ref<Image> image) {
|
||||
if(!image.is_valid()) {
|
||||
return PoolIntArray();
|
||||
}
|
||||
ERR_FAIL_COND_V(!image.is_valid(), PoolIntArray());
|
||||
|
||||
_colors.resize(0);
|
||||
PoolIntArray color_indices;
|
||||
|
||||
image->lock();
|
||||
|
Loading…
Reference in New Issue
Block a user