From 57707ca9ae55b4001bf5e6da5ef069c730b69fa5 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 21 May 2024 13:13:09 +1000 Subject: [PATCH] Cleanup: const pointers for FCurves where possible --- source/blender/blenkernel/intern/anim_sys.cc | 6 +++--- source/blender/blenkernel/intern/tracking.cc | 2 +- source/blender/editors/animation/drivers.cc | 2 +- source/blender/editors/animation/fmodifier_ui.cc | 2 +- .../blender/editors/animation/keyframes_edit.cc | 4 ++-- .../editors/animation/keyframes_general.cc | 8 ++++---- source/blender/editors/armature/pose_slide.cc | 4 ++-- source/blender/editors/armature/pose_utils.cc | 2 +- source/blender/editors/include/ED_anim_api.hh | 3 ++- .../blender/editors/include/ED_keyframes_edit.hh | 2 +- .../blender/editors/interface/interface_ops.cc | 4 ++-- source/blender/editors/sound/sound_ops.cc | 4 ++-- source/blender/editors/space_graph/graph_draw.cc | 16 ++++++++-------- .../blender/editors/space_graph/graph_select.cc | 7 +++++-- .../editors/space_graph/graph_slider_ops.cc | 2 +- .../blender/editors/space_graph/graph_utils.cc | 6 +++--- source/blender/editors/space_nla/nla_draw.cc | 2 +- .../space_sequencer/sequencer_timeline_draw.cc | 4 ++-- source/blender/io/collada/AnimationImporter.cpp | 2 +- source/blender/io/collada/BCAnimationSampler.cpp | 1 - source/blender/sequencer/intern/effects.cc | 4 ++-- source/blender/sequencer/intern/render.cc | 2 +- 22 files changed, 46 insertions(+), 43 deletions(-) diff --git a/source/blender/blenkernel/intern/anim_sys.cc b/source/blender/blenkernel/intern/anim_sys.cc index 7d029a01c63..22ddf2cf97a 100644 --- a/source/blender/blenkernel/intern/anim_sys.cc +++ b/source/blender/blenkernel/intern/anim_sys.cc @@ -327,7 +327,7 @@ void BKE_keyingsets_blend_read_data(BlendDataReader *reader, ListBase *list) /* ***************************************** */ /* Evaluation Data-Setting Backend */ -static bool is_fcurve_evaluatable(FCurve *fcu) +static bool is_fcurve_evaluatable(const FCurve *fcu) { if (fcu->flag & (FCURVE_MUTED | FCURVE_DISABLED)) { return false; @@ -2615,7 +2615,7 @@ static void nlasnapshot_from_action(PointerRNA *ptr, const float modified_evaltime = evaluate_time_fmodifiers( &storage, modifiers, nullptr, 0.0f, evaltime); - LISTBASE_FOREACH (FCurve *, fcu, &action->curves) { + LISTBASE_FOREACH (const FCurve *, fcu, &action->curves) { if (!is_fcurve_evaluatable(fcu)) { continue; } @@ -3087,7 +3087,7 @@ static void nla_eval_domain_action(PointerRNA *ptr, return; } - LISTBASE_FOREACH (FCurve *, fcu, &act->curves) { + LISTBASE_FOREACH (const FCurve *, fcu, &act->curves) { /* check if this curve should be skipped */ if (!is_fcurve_evaluatable(fcu)) { continue; diff --git a/source/blender/blenkernel/intern/tracking.cc b/source/blender/blenkernel/intern/tracking.cc index 2df2809f333..4202e063914 100644 --- a/source/blender/blenkernel/intern/tracking.cc +++ b/source/blender/blenkernel/intern/tracking.cc @@ -1173,7 +1173,7 @@ float BKE_tracking_track_get_weight_for_marker(MovieClip *clip, MovieTrackingTrack *track, MovieTrackingMarker *marker) { - FCurve *weight_fcurve; + const FCurve *weight_fcurve; float weight = track->weight; weight_fcurve = id_data_find_fcurve( diff --git a/source/blender/editors/animation/drivers.cc b/source/blender/editors/animation/drivers.cc index 87970a7b31a..8c45bea947f 100644 --- a/source/blender/editors/animation/drivers.cc +++ b/source/blender/editors/animation/drivers.cc @@ -919,7 +919,7 @@ static bool add_driver_button_poll(bContext *C) } /* Don't do anything if there is an fcurve for animation without a driver. */ - FCurve *fcu = BKE_fcurve_find_by_rna_context_ui( + const FCurve *fcu = BKE_fcurve_find_by_rna_context_ui( C, &ptr, prop, index, nullptr, nullptr, &driven, &special); return (fcu == nullptr || fcu->driver); } diff --git a/source/blender/editors/animation/fmodifier_ui.cc b/source/blender/editors/animation/fmodifier_ui.cc index 365e2c180bb..42fe9017b6e 100644 --- a/source/blender/editors/animation/fmodifier_ui.cc +++ b/source/blender/editors/animation/fmodifier_ui.cc @@ -86,7 +86,7 @@ static PointerRNA *fmodifier_get_pointers(const bContext *C, const Panel *panel, } if (C != nullptr && CTX_wm_space_graph(C)) { - FCurve *fcu = ANIM_graph_context_fcurve(C); + const FCurve *fcu = ANIM_graph_context_fcurve(C); uiLayoutSetActive(panel->layout, !(fcu->flag & FCURVE_MOD_OFF)); } diff --git a/source/blender/editors/animation/keyframes_edit.cc b/source/blender/editors/animation/keyframes_edit.cc index a53969d9fdb..35b4332f660 100644 --- a/source/blender/editors/animation/keyframes_edit.cc +++ b/source/blender/editors/animation/keyframes_edit.cc @@ -1635,7 +1635,7 @@ KeyframeEditFunc ANIM_editkeyframes_select(short selectmode) static short selmap_build_bezier_more(KeyframeEditData *ked, BezTriple *bezt) { - FCurve *fcu = ked->fcu; + const FCurve *fcu = ked->fcu; char *map = static_cast(ked->data); int i = ked->curIndex; @@ -1670,7 +1670,7 @@ static short selmap_build_bezier_more(KeyframeEditData *ked, BezTriple *bezt) static short selmap_build_bezier_less(KeyframeEditData *ked, BezTriple *bezt) { - FCurve *fcu = ked->fcu; + const FCurve *fcu = ked->fcu; char *map = static_cast(ked->data); int i = ked->curIndex; diff --git a/source/blender/editors/animation/keyframes_general.cc b/source/blender/editors/animation/keyframes_general.cc index 20b2fd8ce83..9e4f6c59582 100644 --- a/source/blender/editors/animation/keyframes_general.cc +++ b/source/blender/editors/animation/keyframes_general.cc @@ -333,7 +333,7 @@ void blend_to_neighbor_fcurve_segment(FCurve *fcu, FCurveSegment *segment, const /* ---------------- */ -float get_default_rna_value(FCurve *fcu, PropertyRNA *prop, PointerRNA *ptr) +float get_default_rna_value(const FCurve *fcu, PropertyRNA *prop, PointerRNA *ptr) { const int len = RNA_property_array_length(ptr, prop); @@ -1433,7 +1433,7 @@ static void flip_names(tAnimCopybufItem *aci, char **r_name) /* ------------------- */ /* most strict method: exact matches only */ -static tAnimCopybufItem *pastebuf_match_path_full(FCurve *fcu, +static tAnimCopybufItem *pastebuf_match_path_full(const FCurve *fcu, const short from_single, const short to_simple, bool flip) @@ -1466,7 +1466,7 @@ static tAnimCopybufItem *pastebuf_match_path_full(FCurve *fcu, /* medium match strictness: path match only (i.e. ignore ID) */ static tAnimCopybufItem *pastebuf_match_path_property(Main *bmain, - FCurve *fcu, + const FCurve *fcu, const short from_single, const short /*to_simple*/) { @@ -1517,7 +1517,7 @@ static tAnimCopybufItem *pastebuf_match_path_property(Main *bmain, } /* least strict matching heuristic: indices only */ -static tAnimCopybufItem *pastebuf_match_index_only(FCurve *fcu, +static tAnimCopybufItem *pastebuf_match_index_only(const FCurve *fcu, const short from_single, const short /*to_simple*/) { diff --git a/source/blender/editors/armature/pose_slide.cc b/source/blender/editors/armature/pose_slide.cc index b233c5ca78a..c22c256b699 100644 --- a/source/blender/editors/armature/pose_slide.cc +++ b/source/blender/editors/armature/pose_slide.cc @@ -577,7 +577,7 @@ static void pose_slide_apply_props(tPoseSlideOp *pso, */ static void pose_slide_apply_quat(tPoseSlideOp *pso, tPChanFCurveLink *pfl) { - FCurve *fcu_w = nullptr, *fcu_x = nullptr, *fcu_y = nullptr, *fcu_z = nullptr; + const FCurve *fcu_w = nullptr, *fcu_x = nullptr, *fcu_y = nullptr, *fcu_z = nullptr; bPoseChannel *pchan = pfl->pchan; LinkData *ld = nullptr; char *path = nullptr; @@ -1751,7 +1751,7 @@ static float find_last_key(ListBase *pflinks) float target_frame = FLT_MIN; LISTBASE_FOREACH (tPChanFCurveLink *, pfl, pflinks) { LISTBASE_FOREACH (LinkData *, ld, &pfl->fcurves) { - FCurve *fcu = (FCurve *)ld->data; + const FCurve *fcu = (const FCurve *)ld->data; if (!fcu->bezt) { continue; } diff --git a/source/blender/editors/armature/pose_utils.cc b/source/blender/editors/armature/pose_utils.cc index 200fa3b4bcc..a8047331d37 100644 --- a/source/blender/editors/armature/pose_utils.cc +++ b/source/blender/editors/armature/pose_utils.cc @@ -323,7 +323,7 @@ LinkData *poseAnim_mapping_getNextFCurve(ListBase *fcuLinks, LinkData *prev, con /* check each link to see if the linked F-Curve has a matching path */ for (ld = first; ld; ld = ld->next) { - FCurve *fcu = (FCurve *)ld->data; + const FCurve *fcu = (const FCurve *)ld->data; /* check if paths match */ if (STREQ(path, fcu->rna_path)) { diff --git a/source/blender/editors/include/ED_anim_api.hh b/source/blender/editors/include/ED_anim_api.hh index f5a8e4464eb..82f9be154ab 100644 --- a/source/blender/editors/include/ED_anim_api.hh +++ b/source/blender/editors/include/ED_anim_api.hh @@ -966,7 +966,8 @@ short ANIM_get_normalization_flags(SpaceLink *space_link); /** * Get unit conversion factor for given ID + F-Curve. */ -float ANIM_unit_mapping_get_factor(Scene *scene, ID *id, FCurve *fcu, short flag, float *r_offset); +float ANIM_unit_mapping_get_factor( + Scene *scene, const ID *id, FCurve *fcu, short flag, float *r_offset); /** \} */ diff --git a/source/blender/editors/include/ED_keyframes_edit.hh b/source/blender/editors/include/ED_keyframes_edit.hh index 80485c27c9a..f962bd16bce 100644 --- a/source/blender/editors/include/ED_keyframes_edit.hh +++ b/source/blender/editors/include/ED_keyframes_edit.hh @@ -417,7 +417,7 @@ bool keyframe_region_circle_test(const KeyframeEdit_CircleData *data_circle, con /* Destructive Editing API `keyframes_general.cc`. */ bool duplicate_fcurve_keys(FCurve *fcu); -float get_default_rna_value(FCurve *fcu, PropertyRNA *prop, PointerRNA *ptr); +float get_default_rna_value(const FCurve *fcu, PropertyRNA *prop, PointerRNA *ptr); struct FCurveSegment { FCurveSegment *next, *prev; diff --git a/source/blender/editors/interface/interface_ops.cc b/source/blender/editors/interface/interface_ops.cc index ef0e4724fa9..c4490c41246 100644 --- a/source/blender/editors/interface/interface_ops.cc +++ b/source/blender/editors/interface/interface_ops.cc @@ -1045,7 +1045,7 @@ static void ui_context_fcurve_modifiers_via_fcurve(bContext *C, } r_lb->clear(); for (const PointerRNA &ptr : fcurve_links) { - FCurve *fcu = static_cast(ptr.data); + const FCurve *fcu = static_cast(ptr.data); LISTBASE_FOREACH (FModifier *, mod, &fcu->modifiers) { if (STREQ(mod->name, source->name) && mod->type == source->type) { r_lb->append(RNA_pointer_create(ptr.owner_id, &RNA_FModifier, mod)); @@ -1616,7 +1616,7 @@ blender::Vector get_property_drivers( * nullptr, return an empty vector for clarity. That way the caller gets * either a useful result or an empty one. */ bool fetched_at_least_one = false; - for (FCurve *driver : drivers) { + for (const FCurve *driver : drivers) { fetched_at_least_one |= driver != nullptr; } if (!fetched_at_least_one) { diff --git a/source/blender/editors/sound/sound_ops.cc b/source/blender/editors/sound/sound_ops.cc index d67bf355bb0..3295d5e4a2f 100644 --- a/source/blender/editors/sound/sound_ops.cc +++ b/source/blender/editors/sound/sound_ops.cc @@ -194,7 +194,7 @@ static void sound_update_animation_flags(Scene *scene); static bool sound_update_animation_flags_fn(Sequence *seq, void *user_data) { - FCurve *fcu; + const FCurve *fcu; Scene *scene = (Scene *)user_data; bool driven; @@ -234,7 +234,7 @@ static bool sound_update_animation_flags_fn(Sequence *seq, void *user_data) static void sound_update_animation_flags(Scene *scene) { - FCurve *fcu; + const FCurve *fcu; bool driven; if (scene->id.tag & LIB_TAG_DOIT) { diff --git a/source/blender/editors/space_graph/graph_draw.cc b/source/blender/editors/space_graph/graph_draw.cc index 28620b3e8fb..87b5389ac43 100644 --- a/source/blender/editors/space_graph/graph_draw.cc +++ b/source/blender/editors/space_graph/graph_draw.cc @@ -47,13 +47,13 @@ static void graph_draw_driver_debug(bAnimContext *ac, ID *id, FCurve *fcu); * drawing components for some F-Curve (fcu) * - selected F-Curves should be more visible than partially visible ones */ -static float fcurve_display_alpha(FCurve *fcu) +static float fcurve_display_alpha(const FCurve *fcu) { return (fcu->flag & FCURVE_SELECTED) ? 1.0f : U.fcu_inactive_alpha; } /** Get the first and last index to the bezt array that are just outside min and max. */ -static blender::IndexRange get_bounding_bezt_index_range(FCurve *fcu, +static blender::IndexRange get_bounding_bezt_index_range(const FCurve *fcu, const float min, const float max) { @@ -415,7 +415,7 @@ static void draw_fcurve_vertices(ARegion *region, /* Handles ---------------- */ -static bool draw_fcurve_handles_check(SpaceGraph *sipo, FCurve *fcu) +static bool draw_fcurve_handles_check(const SpaceGraph *sipo, const FCurve *fcu) { /* don't draw handle lines if handles are not to be shown */ if (/* handles shouldn't be shown anywhere */ @@ -437,7 +437,7 @@ static bool draw_fcurve_handles_check(SpaceGraph *sipo, FCurve *fcu) /* draw lines for F-Curve handles only (this is only done in EditMode) * NOTE: draw_fcurve_handles_check must be checked before running this. */ -static void draw_fcurve_handles(SpaceGraph *sipo, ARegion *region, FCurve *fcu) +static void draw_fcurve_handles(SpaceGraph *sipo, ARegion *region, const FCurve *fcu) { using namespace blender; @@ -538,7 +538,7 @@ static void draw_fcurve_handles(SpaceGraph *sipo, ARegion *region, FCurve *fcu) /* Samples ---------------- */ /* helper func - draw keyframe vertices only for an F-Curve */ -static void draw_fcurve_samples(ARegion *region, FCurve *fcu, const float unit_scale) +static void draw_fcurve_samples(ARegion *region, const FCurve *fcu, const float unit_scale) { FPoint *first, *last; float scale[2]; @@ -585,7 +585,7 @@ static void draw_fcurve_samples(ARegion *region, FCurve *fcu, const float unit_s * (for drawing curves with modifiers). */ static void draw_fcurve_curve(bAnimContext *ac, ID *id, - FCurve *fcu_, + const FCurve *fcu_, View2D *v2d, uint pos, const bool use_nla_remap, @@ -903,7 +903,7 @@ static void add_bezt_vertices(BezTriple *bezt, MEM_freeN(bezier_diff_points); } -static void add_extrapolation_point_left(FCurve *fcu, +static void add_extrapolation_point_left(const FCurve *fcu, const float v2d_xmin, blender::Vector &curve_vertices) { @@ -940,7 +940,7 @@ static void add_extrapolation_point_left(FCurve *fcu, curve_vertices.append(vertex_position); } -static void add_extrapolation_point_right(FCurve *fcu, +static void add_extrapolation_point_right(const FCurve *fcu, const float v2d_xmax, blender::Vector &curve_vertices) { diff --git a/source/blender/editors/space_graph/graph_select.cc b/source/blender/editors/space_graph/graph_select.cc index cc8e3ad51a2..8be3cd9eff4 100644 --- a/source/blender/editors/space_graph/graph_select.cc +++ b/source/blender/editors/space_graph/graph_select.cc @@ -703,8 +703,11 @@ static int rectf_curve_zone_y(const FCurve *fcu, * only keyframes, but also all the interpolated values). This is done by sampling the curve at * different points between the xmin and the xmax of the rectangle. */ -static bool rectf_curve_intersection( - const float offset, const float unit_scale, const rctf *rectf, AnimData *adt, FCurve *fcu) +static bool rectf_curve_intersection(const float offset, + const float unit_scale, + const rctf *rectf, + AnimData *adt, + const FCurve *fcu) { /* 30 sampling points. This worked well in tests. */ int num_steps = 30; diff --git a/source/blender/editors/space_graph/graph_slider_ops.cc b/source/blender/editors/space_graph/graph_slider_ops.cc index c07edfc4603..3a36fa883d1 100644 --- a/source/blender/editors/space_graph/graph_slider_ops.cc +++ b/source/blender/editors/space_graph/graph_slider_ops.cc @@ -159,7 +159,7 @@ static void store_original_bezt_arrays(tGraphSliderOp *gso) /* Loop through filtered data and copy the curves. */ LISTBASE_FOREACH (bAnimListElem *, ale, &anim_data) { - FCurve *fcu = (FCurve *)ale->key_data; + const FCurve *fcu = (const FCurve *)ale->key_data; if (fcu->bezt == nullptr) { /* This curve is baked, skip it. */ diff --git a/source/blender/editors/space_graph/graph_utils.cc b/source/blender/editors/space_graph/graph_utils.cc index 664bb322382..6ae92ae55c9 100644 --- a/source/blender/editors/space_graph/graph_utils.cc +++ b/source/blender/editors/space_graph/graph_utils.cc @@ -138,7 +138,7 @@ bool graphop_visible_keyframes_poll(bContext *C) } LISTBASE_FOREACH (bAnimListElem *, ale, &anim_data) { - FCurve *fcu = (FCurve *)ale->data; + const FCurve *fcu = (const FCurve *)ale->data; /* visible curves for selection must fulfill the following criteria: * - it has bezier keyframes @@ -192,7 +192,7 @@ bool graphop_editable_keyframes_poll(bContext *C) } LISTBASE_FOREACH (bAnimListElem *, ale, &anim_data) { - FCurve *fcu = (FCurve *)ale->data; + const FCurve *fcu = (const FCurve *)ale->data; /* editable curves must fulfill the following criteria: * - it has bezier keyframes @@ -247,7 +247,7 @@ bool graphop_active_fcurve_poll(bContext *C) */ has_fcurve = ((ale->data) && ELEM(ale->type, ANIMTYPE_FCURVE, ANIMTYPE_NLACURVE)); if (has_fcurve) { - FCurve *fcu = (FCurve *)ale->data; + const FCurve *fcu = (const FCurve *)ale->data; has_fcurve = (fcu->flag & FCURVE_VISIBLE) != 0; } diff --git a/source/blender/editors/space_nla/nla_draw.cc b/source/blender/editors/space_nla/nla_draw.cc index 938385359c2..907e43dfb0c 100644 --- a/source/blender/editors/space_nla/nla_draw.cc +++ b/source/blender/editors/space_nla/nla_draw.cc @@ -308,7 +308,7 @@ static void nla_draw_strip_curves(NlaStrip *strip, float yminc, float ymaxc, uin /* influence -------------------------- */ if (strip->flag & NLASTRIP_FLAG_USR_INFLUENCE) { - FCurve *fcu = BKE_fcurve_find(&strip->fcurves, "influence", 0); + const FCurve *fcu = BKE_fcurve_find(&strip->fcurves, "influence", 0); /* plot the curve (over the strip's main region) */ if (fcu) { diff --git a/source/blender/editors/space_sequencer/sequencer_timeline_draw.cc b/source/blender/editors/space_sequencer/sequencer_timeline_draw.cc index 550a795652d..99a60161b70 100644 --- a/source/blender/editors/space_sequencer/sequencer_timeline_draw.cc +++ b/source/blender/editors/space_sequencer/sequencer_timeline_draw.cc @@ -502,7 +502,7 @@ static void draw_seq_waveform_overlay(TimelineDrawContext *timeline_ctx, } /* F-Curve lookup is quite expensive, so do this after precondition. */ - FCurve *fcu = id_data_find_fcurve(&scene->id, seq, &RNA_Sequence, "volume", 0, nullptr); + const FCurve *fcu = id_data_find_fcurve(&scene->id, seq, &RNA_Sequence, "volume", 0, nullptr); /* Draw zero line (when actual samples close to zero are drawn, they might not cover a pixel. */ uchar color[4] = {255, 255, 255, 127}; @@ -1394,7 +1394,7 @@ static void draw_seq_fcurve_overlay(TimelineDrawContext *timeline_ctx, const int eval_step = max_ii(1, floor(timeline_ctx->pixelx)); uchar color[4] = {0, 0, 0, 38}; - FCurve *fcu; + const FCurve *fcu; if (strip_ctx->seq->type == SEQ_TYPE_SOUND_RAM) { fcu = id_data_find_fcurve(&scene->id, strip_ctx->seq, &RNA_Sequence, "volume", 0, nullptr); } diff --git a/source/blender/io/collada/AnimationImporter.cpp b/source/blender/io/collada/AnimationImporter.cpp index fc33b8e98ed..1b25eca3cf9 100644 --- a/source/blender/io/collada/AnimationImporter.cpp +++ b/source/blender/io/collada/AnimationImporter.cpp @@ -1336,7 +1336,7 @@ bool AnimationImporter::evaluate_animation(COLLADAFW::Transformation *tm, COLLADABU::Math::Matrix4 matrix; int mi = 0, mj = 0; - for (FCurve *curve : curves) { + for (const FCurve *curve : curves) { matrix.setElement(mi, mj, evaluate_fcurve(curve, fra)); mj++; if (mj == 4) { diff --git a/source/blender/io/collada/BCAnimationSampler.cpp b/source/blender/io/collada/BCAnimationSampler.cpp index ca4ec97566e..a410922693e 100644 --- a/source/blender/io/collada/BCAnimationSampler.cpp +++ b/source/blender/io/collada/BCAnimationSampler.cpp @@ -101,7 +101,6 @@ static bool is_object_keyframe(Object *ob, int frame_index) static void add_keyframes_from(bAction *action, BCFrameSet &frameset) { if (action) { - FCurve *fcu = nullptr; LISTBASE_FOREACH (FCurve *, fcu, &action->curves) { BezTriple *bezt = fcu->bezt; for (int i = 0; i < fcu->totvert; bezt++, i++) { diff --git a/source/blender/sequencer/intern/effects.cc b/source/blender/sequencer/intern/effects.cc index 05cffb5e8a8..a70b73c4638 100644 --- a/source/blender/sequencer/intern/effects.cc +++ b/source/blender/sequencer/intern/effects.cc @@ -2190,7 +2190,7 @@ void seq_effect_speed_rebuild_map(Scene *scene, Sequence *seq) return; /* Make COVERITY happy and check for (CID 598) input strip. */ } - FCurve *fcu = seq_effect_speed_speed_factor_curve_get(scene, seq); + const FCurve *fcu = seq_effect_speed_speed_factor_curve_get(scene, seq); if (fcu == nullptr) { return; } @@ -2249,7 +2249,7 @@ float seq_speed_effect_target_frame_get(Scene *scene, break; } case SEQ_SPEED_MULTIPLY: { - FCurve *fcu = seq_effect_speed_speed_factor_curve_get(scene, seq_speed); + const FCurve *fcu = seq_effect_speed_speed_factor_curve_get(scene, seq_speed); if (fcu != nullptr) { seq_effect_speed_frame_map_ensure(scene, seq_speed); target_frame = s->frameMap[frame_index]; diff --git a/source/blender/sequencer/intern/render.cc b/source/blender/sequencer/intern/render.cc index 0550c65cfcd..0750b57d577 100644 --- a/source/blender/sequencer/intern/render.cc +++ b/source/blender/sequencer/intern/render.cc @@ -883,7 +883,7 @@ static ImBuf *seq_render_effect_strip_impl(const SeqRenderData *context, float fac; int i; SeqEffectHandle sh = SEQ_effect_handle_get(seq); - FCurve *fcu = nullptr; + const FCurve *fcu = nullptr; ImBuf *ibuf[3]; Sequence *input[3]; ImBuf *out = nullptr;