|
Blender V4.3
|
#include <algorithm>#include "BLI_listbase.h"#include "BLI_math_matrix.h"#include "BLI_math_rotation.h"#include "BLI_string.h"#include "BLI_utildefines.h"#include "DNA_anim_types.h"#include "DNA_armature_types.h"#include "DNA_brush_types.h"#include "DNA_cachefile_types.h"#include "DNA_collection_types.h"#include "DNA_constraint_types.h"#include "DNA_fluid_types.h"#include "DNA_genfile.h"#include "DNA_gpencil_legacy_types.h"#include "DNA_gpencil_modifier_types.h"#include "DNA_light_types.h"#include "DNA_mesh_types.h"#include "DNA_meshdata_types.h"#include "DNA_modifier_types.h"#include "DNA_object_types.h"#include "DNA_particle_types.h"#include "DNA_pointcloud_types.h"#include "DNA_rigidbody_types.h"#include "DNA_screen_types.h"#include "DNA_sequence_types.h"#include "DNA_shader_fx_types.h"#include "DNA_space_types.h"#include "DNA_text_types.h"#include "DNA_tracking_types.h"#include "DNA_workspace_types.h"#include "BKE_armature.hh"#include "BKE_collection.hh"#include "BKE_colortools.hh"#include "BKE_cryptomatte.h"#include "BKE_curve.hh"#include "BKE_customdata.hh"#include "BKE_fcurve.hh"#include "BKE_gpencil_legacy.h"#include "BKE_lib_id.hh"#include "BKE_main.hh"#include "BKE_mesh.hh"#include "BKE_mesh_legacy_convert.hh"#include "BKE_multires.hh"#include "BKE_node.hh"#include "IMB_imbuf.hh"#include "MEM_guardedalloc.h"#include "SEQ_proxy.hh"#include "SEQ_sequencer.hh"#include "SEQ_time.hh"#include "BLO_readfile.hh"#include "readfile.hh"#include "versioning_common.hh"Go to the source code of this file.
Macros | |
| #define | DNA_DEPRECATED_ALLOW |
| #define | DNA_GENFILE_VERSIONING_MACROS |
| #define | U (*((const UserDef *)&U)) |
| #define | CU_2D (1 << 3) |
| #define CU_2D (1 << 3) |
Referenced by blo_do_versions_290().
| #define DNA_DEPRECATED_ALLOW |
Definition at line 9 of file versioning_290.cc.
| #define DNA_GENFILE_VERSIONING_MACROS |
Definition at line 20 of file versioning_290.cc.
Repair files from duplicate brushes added to blend files, see: #76738.
Always bump subversion in BKE_blender_version.h when adding versioning code here, and wrap it inside a MAIN_VERSION_FILE_ATLEAST check.
Definition at line 811 of file versioning_290.cc.
References Main::actions, BevelModifierData::affect_type, ARegion::alignment, Main::armatures, ARRAY_SIZE, MirrorModifierData::bisect_threshold, BKE_cryptomatte_matte_id_to_entries(), BKE_curve_nurbs_get(), BKE_curvemapping_add(), BKE_curvemapping_init(), BKE_main_id_repair_duplicate_names_listbase(), BKE_mesh_legacy_convert_loops_to_corners(), BKE_mesh_legacy_convert_polys_to_offsets(), BKE_mesh_validate_arrays(), BLI_assert, BLI_assert_msg, BLI_findptr(), BLI_freelinkN(), blo_read_get_new_globaldata_address(), Main::brushes, Editing::cache_flag, CACHEFILE_VELOCITY_UNIT_SECOND, Main::cachefiles, CD_MFACE, WeightVGProximityModifierData::cmap_curve, CMP_NODE_SETALPHA_MODE_REPLACE_ALPHA, FluidDomainSettings::coba_field, COLLECTION_COLOR_NONE, Main::collections, copy_v3_fl(), copy_v4_v4(), CU_2D, CU_3D, CU_BEV_MODE_OBJECT, CU_BEV_MODE_ROUND, CU_IS_2D, CU_PATH_CLAMP, Main::curves, CustomData_get_layer(), CustomData_get_layer_for_write(), data, IDProperty::data, DEG2RADF, DENOISER_OPTIX, do_versions_291_fcurve_handles_limit(), do_versions_add_region_if_not_found(), do_versions_point_attribute_names(), do_versions_point_attributes(), do_versions_strip_cache_settings_recursive(), FluidModifierData::domain, eBooleanModifierFlag_Object, eBooleanModifierSolver_Float, ELEM, eModifierType_Bevel, eModifierType_Boolean, eModifierType_Fluid, eModifierType_MeshSequenceCache, eModifierType_Mirror, eModifierType_Nodes, eModifierType_Ocean, eModifierType_WeightVGEdit, eModifierType_WeightVGProximity, View3DOverlay::fade_alpha, FileData::filesdna, SpaceOutliner::filter, SpaceOutliner::filter_state, BooleanModifierData::flag, SpaceImage::flag, SpaceImageOverlay::flag, SpaceOutliner::flag, SpaceSeq::flag, View3DOverlay::flag, BevelModifierData::flags, FLUID_DOMAIN_FIELD_PHI, FLUID_DOMAIN_TYPE_LIQUID, FOREACH_NODETREE_BEGIN, FOREACH_NODETREE_END, FPS, FluidDomainSettings::fractions_distance, GEO_NODE_TRANSFORM_SPACE_RELATIVE, GP_DATA_CURVE_ADAPTIVE_RESOLUTION, GP_DEFAULT_CURVE_EDIT_CORNER_ANGLE, GP_DEFAULT_CURVE_ERROR, GP_DEFAULT_CURVE_RESOLUTION, Main::gpencils, FluidDomainSettings::grid_scale, FluidDomainSettings::gridlines_range_color, FluidDomainSettings::gridlines_upper_bound, IDPropertyData::group, ID_BR, ID_PAL, IDP_FLAG_OVERRIDABLE_LIBRARY, IDP_GROUP, invert_m4_m4(), Main::lights, LISTBASE_FOREACH, LISTBASE_FOREACH_MUTABLE, loc_eul_size_to_mat4(), M_PI_2, MAIN_VERSION_FILE_ATLEAST, MAIN_VERSION_FILE_OLDER, NodeCryptomatte::matte_id, MAX_NAME, ME_SYMMETRY_X, ME_SYMMETRY_Y, ME_SYMMETRY_Z, MEM_allocN_len, MEM_callocN, Main::meshes, MOD_BEVEL_AFFECT_EDGES, MOD_BEVEL_AFFECT_VERTICES, MOD_BEVEL_PROFILE_CUSTOM, MOD_BEVEL_PROFILE_SUPERELLIPSE, MOD_MESHSEQ_INTERPOLATE_VERTICES, NodeSetAlpha::mode, Main::movieclips, Main::nodetrees, NTREE_COMPOSIT, NTREE_GEOMETRY, NTREE_SHADER, SpaceSpreadsheet::object_eval_state, Main::objects, offsetof, SpaceProperties::outliner_sync, SpaceImage::overlay, View3D::overlay, panels_remove_x_closed_flag_recursive(), PART_FLUID_BUBBLE, PART_FLUID_FLIP, PART_FLUID_FOAM, PART_FLUID_SPRAY, PART_PHYS_NO, Main::particles, Main::pointclouds, BevelModifierData::profile_type, NodesModifierSettings::properties, PROPERTIES_SYNC_AUTO, RE_PASSNAME_VOLUME_LIGHT, MeshSeqCacheModifierData::read_flag, MovieTrackingSettings::refine_camera_intrinsics, REFINE_FOCAL_LENGTH, REFINE_PRINCIPAL_POINT, REFINE_RADIAL_DISTORTION, SpaceSeq::render_size, OceanModifierData::resolution, RGN_ALIGN_BOTTOM, RGN_ALIGN_TOP, RGN_TYPE_FOOTER, RGN_TYPE_HEADER, NodeImageMultiFileSocket::save_as_render, Main::scenes, Main::screens, SEQ_CACHE_STORE_FINAL_OUT, SEQ_CACHE_STORE_RAW, SEQ_editing_get(), SEQ_RENDER_SIZE_FULL, SEQ_RENDER_SIZE_PROXY_100, SEQ_RENDER_SIZE_PROXY_25, SEQ_RENDER_SIZE_PROXY_50, SEQ_RENDER_SIZE_PROXY_75, SEQ_SHOW_OVERLAY, SEQ_TIMELINE_SHOW_STRIP_DURATION, SEQ_TIMELINE_SHOW_STRIP_NAME, SEQ_TIMELINE_SHOW_STRIP_SOURCE, SEQ_tool_settings_init(), SEQ_USE_PROXIES, Editing::seqbase, SET_FLAG_FROM_TEST, NodesModifierData::settings, SH_NODE_TEX_SKY, OceanModifierData::sharpen_peak_jonswap, SpaceOutliner::show_restrict_flags, SI_FLAG_UNUSED_20, SI_OVERLAY_SHOW_OVERLAYS, SO_FILTER_OB_HIDDEN, SO_FILTER_OB_STATE_INVERSE, SO_FILTER_OB_VISIBLE, SO_MODE_COLUMN, SO_RESTRICT_RENDER, BooleanModifierData::solver, SPACE_IMAGE, SPACE_NODE, SPACE_OUTLINER, SPACE_PROPERTIES, SPACE_SEQ, SPACE_SPREADSHEET, SPACE_VIEW3D, SPREADSHEET_OBJECT_EVAL_STATE_EVALUATED, STREQ, STREQLEN, STRNCPY, RigidBodyWorld::substeps_per_frame, tex, NodeGeometryObjectInfo::transform_space, SpaceNode::treepath, FluidDomainSettings::type, IDProperty::type, UI_PANEL_DATA_EXPAND_ROOT, UNUSED_VARS, USER_HEADER_BOTTOM, SpaceImage::uv_opacity, V3D_OVERLAY_FADE_INACTIVE, FluidDomainSettings::vector_scale_with_magnitude, MeshSeqCacheModifierData::velocity_scale, version_cycles_properties_from_ID(), version_cycles_properties_from_render_layer(), version_cycles_properties_from_view_layer(), version_cycles_property_boolean(), version_cycles_property_boolean_set(), version_cycles_property_int(), version_cycles_property_int_set(), version_node_join_geometry_for_multi_input_socket(), version_node_socket_name(), Main::versionfile, VIEW_LAYER_CRYPTOMATTE_ACCURATE, OceanModifierData::viewport_resolution, FluidDomainSettings::viscosity_value, OceanModifierData::wave_alignment, which_libbase(), wmWindow::winid, View3DOverlay::wireframe_opacity, Main::wm, Main::workspaces, and zero_v3().
Referenced by do_versions().
Definition at line 102 of file versioning_290.cc.
References StripProxy::build_size_flags, Sequence::flag, IMB_PROXY_NONE, Strip::proxy, SEQ_USE_PROXY, and Sequence::strip.
Referenced by seq_convert_transform_crop(), and seq_convert_transform_crop_2().
|
static |
Definition at line 739 of file versioning_290.cc.
References FCurve::bezt, BEZT_IPO_BEZ, fabsf, madd_v2_v2v2fl(), sub_v2_v2v2(), FCurve::totvert, v2, and BezTriple::vec.
Referenced by blo_do_versions_290().
Make sure Emission Alpha fcurve and drivers is properly mapped after the Emission Strength got introduced.
Effectively we are replacing the (animation of) node socket input 18 with 19. Emission Strength is the new socket input 18, pushing Emission Alpha to input 19.
To play safe we move all the inputs beyond 18 to their rightful new place. In case users are doing unexpected things with not-really supported keyframeable channels.
Always bump subversion in BKE_blender_version.h when adding versioning code here, and wrap it inside a MAIN_VERSION_FILE_ATLEAST check.
Definition at line 419 of file versioning_290.cc.
References BKE_collection_cycles_fix(), BKE_gpencil_frame_duplicate(), BKE_pose_rebuild(), BLI_addhead(), BLI_findstring(), Main::brushes, Main::collections, eGpencilModifierType_Array, eGpencilModifierType_Color, eGpencilModifierType_Hook, eGpencilModifierType_Lattice, eGpencilModifierType_Mirror, eGpencilModifierType_Multiply, eGpencilModifierType_Noise, eGpencilModifierType_Offset, eGpencilModifierType_Opacity, eGpencilModifierType_Simplify, eGpencilModifierType_Smooth, eGpencilModifierType_Subdiv, eGpencilModifierType_Texture, eGpencilModifierType_Thick, eModifierType_Multires, ListBase::first, FOREACH_NODETREE_BEGIN, FOREACH_NODETREE_END, bGPDframe::framenum, get_sequencer_render_size(), id_fake_user_set(), bGPdata::layers, LISTBASE_FOREACH, MAIN_VERSION_FILE_ATLEAST, ArrayGpencilModifierData::material, ColorGpencilModifierData::material, HookGpencilModifierData::material, LatticeGpencilModifierData::material, MirrorGpencilModifierData::material, MultiplyGpencilModifierData::material, NoiseGpencilModifierData::material, OffsetGpencilModifierData::material, OpacityGpencilModifierData::material, SimplifyGpencilModifierData::material, SmoothGpencilModifierData::material, SubdivGpencilModifierData::material, TextureGpencilModifierData::material, ThickGpencilModifierData::material, Main::materials, multires_do_versions_simple_to_catmull_clark(), NTREE_GEOMETRY, NTREE_SHADER, OB_ARMATURE, OB_GPENCIL_LEGACY, OB_MODE_SCULPT, Main::objects, offsetof, printf, Main::scenes, seq_convert_transform_crop_lb(), seq_convert_transform_crop_lb_2(), seq_update_meta_disp_range(), Main::texts, version_node_socket_duplicate(), and version_node_socket_index_animdata().
Referenced by do_versions_after_linking().
|
static |
Definition at line 721 of file versioning_290.cc.
References CD_PROP_FLOAT, CD_PROP_FLOAT3, CustomData::layers, STREQ, STRNCPY, and CustomData::totlayer.
Referenced by blo_do_versions_290().
|
static |
Definition at line 700 of file versioning_290.cc.
References CD_PROP_FLOAT, CD_PROP_FLOAT3, CustomData::layers, STRNCPY, and CustomData::totlayer.
Referenced by blo_do_versions_290().
|
static |
Definition at line 783 of file versioning_290.cc.
References do_versions_strip_cache_settings_recursive(), LISTBASE_FOREACH, and SEQ_TYPE_META.
Referenced by blo_do_versions_290(), and do_versions_strip_cache_settings_recursive().
|
static |
Definition at line 79 of file versioning_290.cc.
References LISTBASE_FOREACH, SpaceSeq::mainb, SpaceSeq::render_size, Main::screens, SEQ_DRAW_IMG_IMBUF, and SPACE_SEQ.
Referenced by do_versions_after_linking_290().
|
static |
Definition at line 685 of file versioning_290.cc.
References Panel::children, Panel::flag, LISTBASE_FOREACH, panels_remove_x_closed_flag_recursive(), PNL_CLOSED, PNL_UNUSED_1, and SET_FLAG_FROM_TEST.
Referenced by blo_do_versions_290(), and panels_remove_x_closed_flag_recursive().
|
static |
Definition at line 112 of file versioning_290.cc.
References FCurve::bezt, BKE_fcurve_find(), BKE_fcurve_free(), BKE_fcurve_is_empty(), BLI_remlink(), Sequence::flag, FCurve::totvert, and BezTriple::vec.
Referenced by seq_convert_transform_crop().
|
static |
Definition at line 269 of file versioning_290.cc.
References FCurve::bezt, BKE_fcurve_find(), BKE_fcurve_is_empty(), FCurve::totvert, and BezTriple::vec.
Referenced by seq_convert_transform_crop_2().
|
static |
Definition at line 146 of file versioning_290.cc.
References BLI_sprintfN(), BLI_str_escape(), StripCrop::bottom, can_use_proxy(), Strip::crop, Sequence::flag, float, StripCrop::left, MEM_freeN(), Sequence::name, StripElem::orig_height, StripElem::orig_width, StripCrop::right, StripTransform::scale_x, StripTransform::scale_y, seq_convert_transform_animation(), SEQ_rendersize_to_proxysize(), SEQ_rendersize_to_scale_factor(), Sequence::strip, Strip::stripdata, StripCrop::top, Strip::transform, StripTransform::xofs, and StripTransform::yofs.
Referenced by seq_convert_transform_crop_lb().
|
static |
Definition at line 289 of file versioning_290.cc.
References BLI_sprintfN(), BLI_str_escape(), StripCrop::bottom, can_use_proxy(), Strip::crop, StripCrop::left, MEM_freeN(), Sequence::name, StripElem::orig_height, StripElem::orig_width, StripCrop::right, StripTransform::scale_x, StripTransform::scale_y, seq_convert_transform_animation_2(), SEQ_rendersize_to_proxysize(), SEQ_rendersize_to_scale_factor(), Sequence::strip, Strip::stripdata, StripCrop::top, and Strip::transform.
Referenced by seq_convert_transform_crop_lb_2().
|
static |
Definition at line 254 of file versioning_290.cc.
References ELEM, LISTBASE_FOREACH, seq_convert_transform_crop(), seq_convert_transform_crop_lb(), SEQ_TYPE_META, SEQ_TYPE_SOUND_HD, and SEQ_TYPE_SOUND_RAM.
Referenced by do_versions_after_linking_290(), and seq_convert_transform_crop_lb().
|
static |
Definition at line 340 of file versioning_290.cc.
References ELEM, LISTBASE_FOREACH, seq_convert_transform_crop_2(), seq_convert_transform_crop_lb_2(), SEQ_TYPE_META, SEQ_TYPE_SOUND_HD, and SEQ_TYPE_SOUND_RAM.
Referenced by do_versions_after_linking_290(), and seq_convert_transform_crop_lb_2().
|
static |
Definition at line 355 of file versioning_290.cc.
References LISTBASE_FOREACH, LISTBASE_FOREACH_BACKWARD, max_ii(), Editing::metastack, min_ii(), MetaStack::parseq, SEQ_editing_get(), SEQ_meta_stack_active_get(), SEQ_seqbase_active_set(), SEQ_time_left_handle_frame_get(), SEQ_time_left_handle_frame_set(), SEQ_time_right_handle_frame_get(), SEQ_time_right_handle_frame_set(), and Sequence::seqbase.
Referenced by do_versions_after_linking_290().
|
static |
Definition at line 793 of file versioning_290.cc.
References bNodeSocket::flag, bNodeSocket::limit, bNodeTree::links, LISTBASE_FOREACH, LISTBASE_FOREACH_MUTABLE, bNodeSocket::next, blender::bke::node_remove_socket(), bNodeTree::nodes, and SOCK_MULTI_INPUT.
Referenced by blo_do_versions_290().
|
static |
Definition at line 388 of file versioning_290.cc.
References BLI_assert, bNodeSocket::default_value, bNodeTree::links, LISTBASE_FOREACH, LISTBASE_FOREACH_MUTABLE, MEM_dupallocN, MEM_freeN(), blender::bke::node_add_link(), blender::bke::node_find_socket(), bNodeTree::nodes, SOCK_IN, and STREQ.
Referenced by do_versions_after_linking_290().