mirror of
https://github.com/godotengine/godot.git
synced 2025-10-19 16:03:29 +00:00
Add 64-bit versions of core power of 2 functions
This commit is contained in:
parent
64b09905c7
commit
f6f1df7d73
25 changed files with 161 additions and 124 deletions
|
@ -1115,8 +1115,8 @@ bool Image::is_size_po2() const {
|
|||
void Image::resize_to_po2(bool p_square, Interpolation p_interpolation) {
|
||||
ERR_FAIL_COND_MSG(is_compressed(), "Cannot resize in compressed image formats.");
|
||||
|
||||
int w = next_power_of_2(width);
|
||||
int h = next_power_of_2(height);
|
||||
int w = next_power_of_2((uint32_t)width);
|
||||
int h = next_power_of_2((uint32_t)height);
|
||||
if (p_square) {
|
||||
w = h = MAX(w, h);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue