Import 3D Scene Improvements

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

-If re-importing from the "dependency changed" dialog, edited scene will keep the local changes.
-Imported scene will keep track of changes in the source asset
-Geometry changes in source geometry or nodes with a different transform will be updated.
-Materials will be kept if changed locally.
-New nodes added will be kept
-If nodes were reparented or renamed, they will still keep track
-Deleted notes will be restored, use the -noimp option to avoid this.
-In general, you can trust that if you do local modifications to the imported scene, they will not be erased after re-import.
-Erasing your changes is done by re-importing from the "Re-Import" menu, re-opening the "Import 3D Scene" dialog. This wil re-import fresh.

Overall, This should allow you to work on a scene and see changes made to 3D assets in real-time.

So Please test!!
This commit is contained in:
Juan Linietsky
2014-06-19 02:23:03 -03:00
parent ddc0e7fd3b
commit e086bccd63
19 changed files with 667 additions and 124 deletions

View File

@@ -494,6 +494,17 @@ Ref<World> Spatial::get_world() const {
}
#ifdef TOOLS_ENABLED
void Spatial::set_import_transform(const Transform& p_transform) {
data.import_transform=p_transform;
}
Transform Spatial::get_import_transform() const {
return data.import_transform;
}
#endif
void Spatial::_bind_methods() {
@@ -517,6 +528,9 @@ void Spatial::_bind_methods() {
#ifdef TOOLS_ENABLED
ObjectTypeDB::bind_method(_MD("_update_gizmo"), &Spatial::_update_gizmo);
ObjectTypeDB::bind_method(_MD("_set_import_transform"), &Spatial::set_import_transform);
ObjectTypeDB::bind_method(_MD("_get_import_transform"), &Spatial::get_import_transform);
ADD_PROPERTY( PropertyInfo(Variant::TRANSFORM,"_import_transform",PROPERTY_HINT_NONE,"",PROPERTY_USAGE_NOEDITOR),_SCS("_set_import_transform"),_SCS("_get_import_transform"));
#endif
ObjectTypeDB::bind_method(_MD("update_gizmo"), &Spatial::update_gizmo);