checheche/Robo-Bus-A31-HMI/common/util/image_util.gd
2024-12-06 21:22:11 +08:00

7 lines
183 B
GDScript

class_name ImageUtil
extends Object
static func get_image_texture(path:String)->ImageTexture:
var image = Image.load_from_file(path)
return ImageTexture.create_from_image(image)