You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-05 12:10:55 +00:00
Add metadata to resource previews
This commit is contained in:
@@ -798,7 +798,7 @@ bool CurvePreviewGenerator::handles(const String &p_type) const {
|
||||
return p_type == "Curve";
|
||||
}
|
||||
|
||||
Ref<Texture2D> CurvePreviewGenerator::generate(const Ref<Resource> &p_from, const Size2 &p_size) const {
|
||||
Ref<Texture2D> CurvePreviewGenerator::generate(const Ref<Resource> &p_from, const Size2 &p_size, Dictionary &p_metadata) const {
|
||||
Ref<Curve> curve_ref = p_from;
|
||||
ERR_FAIL_COND_V_MSG(curve_ref.is_null(), Ref<Texture2D>(), "It's not a reference to a valid Resource object.");
|
||||
Curve &curve = **curve_ref;
|
||||
|
||||
Reference in New Issue
Block a user