Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/io/io_alembic.c
| Show First 20 Lines • Show All 74 Lines • ▼ Show 20 Lines | static int wm_alembic_export_invoke(bContext *C, wmOperator *op, const wmEvent *event) | ||||
| RNA_boolean_set(op->ptr, "init_scene_frame_range", true); | RNA_boolean_set(op->ptr, "init_scene_frame_range", true); | ||||
| if (!RNA_struct_property_is_set(op->ptr, "filepath")) { | if (!RNA_struct_property_is_set(op->ptr, "filepath")) { | ||||
| Main *bmain = CTX_data_main(C); | Main *bmain = CTX_data_main(C); | ||||
| char filepath[FILE_MAX]; | char filepath[FILE_MAX]; | ||||
| if (BKE_main_blendfile_path(bmain)[0] == '\0') { | if (BKE_main_blendfile_path(bmain)[0] == '\0') { | ||||
| BLI_strncpy(filepath, "untitled", sizeof(filepath)); | BLI_strncpy(filepath, DATA_("untitled"), sizeof(filepath)); | ||||
| } | } | ||||
| else { | else { | ||||
| BLI_strncpy(filepath, BKE_main_blendfile_path(bmain), sizeof(filepath)); | BLI_strncpy(filepath, BKE_main_blendfile_path(bmain), sizeof(filepath)); | ||||
| } | } | ||||
| BLI_path_extension_replace(filepath, sizeof(filepath), ".abc"); | BLI_path_extension_replace(filepath, sizeof(filepath), ".abc"); | ||||
| RNA_string_set(op->ptr, "filepath", filepath); | RNA_string_set(op->ptr, "filepath", filepath); | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 644 Lines • Show Last 20 Lines | |||||