|
Blender
V2.93
|
Go to the source code of this file.
Macros | |
| #define | MOVIECLIP_CACHE_SKIP (1 << 0) |
| #define | MOVIECLIP_DISABLE_RED (1 << 0) |
| #define | MOVIECLIP_DISABLE_GREEN (1 << 1) |
| #define | MOVIECLIP_DISABLE_BLUE (1 << 2) |
| #define | MOVIECLIP_PREVIEW_GRAYSCALE (1 << 3) |
| #define MOVIECLIP_CACHE_SKIP (1 << 0) |
Definition at line 129 of file BKE_movieclip.h.
| #define MOVIECLIP_DISABLE_BLUE (1 << 2) |
Definition at line 134 of file BKE_movieclip.h.
| #define MOVIECLIP_DISABLE_GREEN (1 << 1) |
Definition at line 133 of file BKE_movieclip.h.
| #define MOVIECLIP_DISABLE_RED (1 << 0) |
Definition at line 132 of file BKE_movieclip.h.
| #define MOVIECLIP_PREVIEW_GRAYSCALE (1 << 3) |
Definition at line 135 of file BKE_movieclip.h.
| struct ImBuf* BKE_movieclip_anim_ibuf_for_frame_no_lock | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user | ||
| ) |
Definition at line 1961 of file movieclip.c.
References MovieClip::flag, MovieClipUser::framenr, MCLIP_SRC_MOVIE, movieclip_load_movie_file(), NULL, and MovieClip::source.
Referenced by prefetch_movie_frame().
| void BKE_movieclip_build_proxy_frame | ( | struct MovieClip * | clip, |
| int | clip_flag, | ||
| struct MovieDistortion * | distortion, | ||
| int | cfra, | ||
| int * | build_sizes, | ||
| int | build_count, | ||
| bool | undistorted | ||
| ) |
Definition at line 1855 of file movieclip.c.
References BKE_movieclip_get_ibuf_flag(), MovieClipUser::framenr, get_undistorted_ibuf(), IMB_freeImBuf(), MCLIP_PROXY_RENDER_SIZE_FULL, movieclip_build_proxy_ibuf(), MOVIECLIP_CACHE_SKIP, MovieClipUser::render_flag, and MovieClipUser::render_size.
Referenced by do_movie_proxy().
| void BKE_movieclip_build_proxy_frame_for_ibuf | ( | struct MovieClip * | clip, |
| struct ImBuf * | ibuf, | ||
| struct MovieDistortion * | distortion, | ||
| int | cfra, | ||
| int * | build_sizes, | ||
| int | build_count, | ||
| bool | undistorted | ||
| ) |
Definition at line 1899 of file movieclip.c.
References get_undistorted_ibuf(), IMB_freeImBuf(), and movieclip_build_proxy_ibuf().
Referenced by proxy_task_func().
| void BKE_movieclip_clear_cache | ( | struct MovieClip * | clip | ) |
Definition at line 1674 of file movieclip.c.
References free_buffers().
Referenced by ED_space_clip_set_clip().
| void BKE_movieclip_clear_proxy_cache | ( | struct MovieClip * | clip | ) |
Definition at line 1679 of file movieclip.c.
References MovieClip::cache, IMB_moviecache_cleanup(), MovieClipCache::moviecache, moviecache_check_free_proxy(), and NULL.
Referenced by proxy_endjob().
| void BKE_movieclip_convert_multilayer_ibuf | ( | struct ImBuf * | ibuf | ) |
Definition at line 543 of file movieclip.c.
References BLI_assert, ImBuf::channels, ImBuf::flags, ImBuf::ftype, IB_rectfloat, IMB_exr_close(), IMB_exr_multilayer_convert(), IMB_FTYPE_OPENEXR, ImBuf::mall, NULL, ImBuf::rect_float, and ImBuf::userdata.
Referenced by movieclip_load_sequence_file(), and prefetch_task_func().
Definition at line 2058 of file movieclip.c.
References DEG_debug_print_eval(), depsgraph, MovieClip::id, movieclip_selection_sync(), ID::name, and ID::orig_id.
Referenced by blender::deg::DepsgraphNodeBuilder::build_movieclip().
| void BKE_movieclip_eval_update | ( | struct Depsgraph * | depsgraph, |
| struct Main * | bmain, | ||
| struct MovieClip * | clip | ||
| ) |
Definition at line 2047 of file movieclip.c.
References DEG_debug_print_eval(), depsgraph, MovieClip::id, ID_RECALC_SOURCE, movieclip_eval_update_generic(), movieclip_eval_update_reload(), ID::name, and ID::recalc.
Referenced by blender::deg::DepsgraphNodeBuilder::build_movieclip().
Definition at line 987 of file movieclip.c.
References BKE_main_blendfile_path(), BLI_open(), BLI_path_abs(), BLI_path_basename(), BLI_strncpy(), MovieTracking::camera, detect_clip_source(), file, FILE_MAX, MovieClip::filepath, MovieTrackingCamera::focal, MovieClip::lastsize, movieclip_alloc(), movieclip_calc_length(), movieclip_load_get_size(), MovieCache::name, NULL, O_BINARY, MovieTrackingCamera::sensor_width, str, MovieClip::tracking, and width.
Referenced by BKE_movieclip_file_add_exists_ex(), and seqclipboard_ptr_restore().
Definition at line 1051 of file movieclip.c.
References BKE_movieclip_file_add_exists_ex(), and NULL.
Referenced by open_exec().
| struct MovieClip* BKE_movieclip_file_add_exists_ex | ( | struct Main * | bmain, |
| const char * | filepath, | ||
| bool * | r_exists | ||
| ) |
Definition at line 1023 of file movieclip.c.
References BKE_main_blendfile_path(), BKE_movieclip_file_add(), BLI_path_abs(), BLI_path_cmp, BLI_strncpy(), FILE_MAX, MovieClip::filepath, ListBase::first, MovieClip::id, ID_BLEND_PATH, id_us_plus(), Main::movieclips, ID::next, and str.
Referenced by BKE_movieclip_file_add_exists().
| void BKE_movieclip_filename_for_frame | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user, | ||
| char * | name | ||
| ) |
Definition at line 1939 of file movieclip.c.
References BLI_path_abs(), BLI_strncpy(), FILE_MAX, MovieClip::filepath, MovieClip::flag, MovieClipUser::framenr, get_proxy_fname(), get_sequence_fname(), MovieClip::id, ID_BLEND_PATH_FROM_GLOBAL, if(), MCLIP_PROXY_RENDER_SIZE_FULL, MCLIP_PROXY_RENDER_UNDISTORT, MCLIP_SRC_SEQUENCE, MCLIP_USE_PROXY, MovieCache::name, MovieClipUser::render_flag, MovieClipUser::render_size, and MovieClip::source.
Referenced by prefetch_read_file_to_memory(), proxy_thread_next_frame(), and uiTemplateMovieclipInformation().
| void BKE_movieclip_free_gputexture | ( | struct MovieClip * | clip | ) |
Definition at line 2129 of file movieclip.c.
References BLI_listbase_count(), BLI_pophead(), GPU_texture_free(), MovieClip_Runtime::gputextures, MEM_freeN, NULL, MovieClip::runtime, tex, and TEXTARGET_COUNT.
Referenced by OVERLAY_image_free_movieclips_textures().
Definition at line 1608 of file movieclip.c.
References MovieClip::aspx, MovieClip::aspy, MovieTracking::camera, MovieTrackingCamera::pixel_aspect, and MovieClip::tracking.
Referenced by BKE_mask_coord_from_movieclip(), BKE_mask_coord_to_movieclip(), BKE_mask_point_parent_matrix_get(), and ED_space_clip_get_aspect().
| void BKE_movieclip_get_cache_segments | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user, | ||
| int * | r_totseg, | ||
| int ** | r_points | ||
| ) |
Definition at line 1617 of file movieclip.c.
References MovieClip::cache, MovieClip::flag, IMB_moviecache_get_cache_segments(), MovieClipCache::moviecache, NULL, MovieCache::proxy, MovieClipUser::render_flag, and rendersize_to_proxy().
Referenced by draw_movieclip_cache().
| int BKE_movieclip_get_duration | ( | struct MovieClip * | clip | ) |
Definition at line 1582 of file movieclip.c.
References MovieClip::len, and movieclip_calc_length().
Referenced by clip_set_scene_frames_exec(), prefetch_check_early_out(), SEQ_add_movieclip_strip(), and SEQ_add_reload_new_file().
Definition at line 1591 of file movieclip.c.
References MovieClip::anim, IMB_anim_get_fps(), MCLIP_SRC_MOVIE, movieclip_open_anim_file(), NULL, and MovieClip::source.
Referenced by SEQ_time_sequence_get_fps().
| struct GPUTexture* BKE_movieclip_get_gpu_texture | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | cuser | ||
| ) |
Definition at line 2096 of file movieclip.c.
References BKE_movieclip_get_ibuf(), GPU_texture_create_error(), GPU_texture_mipmap_mode(), MovieClip::id, IMB_create_gpu_texture(), IMB_freeImBuf(), movieclip_get_gputexture_ptr(), ID::name, NULL, ImBuf::rect_float, tex, and TEXTARGET_2D.
Referenced by image_camera_background_texture_get().
| struct ImBuf* BKE_movieclip_get_ibuf | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user | ||
| ) |
Definition at line 1349 of file movieclip.c.
References BKE_movieclip_get_ibuf_flag(), and MovieClip::flag.
Referenced by accessor_get_preprocessed_ibuf(), BKE_movieclip_get_gpu_texture(), BKE_movieclip_get_size(), BKE_movieclip_has_frame(), BKE_movieclip_update_scopes(), blender::compositor::KeyingScreenOperation::buildVoronoiTriangulation(), blender::compositor::MovieClipNode::convertToOperations(), and blender::compositor::MovieClipBaseOperation::initExecution().
| struct ImBuf* BKE_movieclip_get_ibuf_flag | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user, | ||
| int | flag, | ||
| int | cache_flag | ||
| ) |
Definition at line 1354 of file movieclip.c.
References movieclip_get_postprocessed_ibuf().
Referenced by BKE_movieclip_build_proxy_frame(), BKE_movieclip_get_ibuf(), BKE_tracking_refine_marker(), blender::compositor::MovieClipNode::convertToOperations(), detect_features_exec(), blender::compositor::MovieClipBaseOperation::initExecution(), seq_get_movieclip_ibuf(), tracking_context_get_frame_ibuf(), and uiTemplateMovieclipInformation().
| struct ImBuf* BKE_movieclip_get_postprocessed_ibuf | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user, | ||
| int | postprocess_flag | ||
| ) |
Definition at line 1359 of file movieclip.c.
References MovieClip::flag, and movieclip_get_postprocessed_ibuf().
Referenced by BKE_movieclip_get_stable_ibuf(), and ED_space_clip_get_buffer().
| void BKE_movieclip_get_size | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user, | ||
| int * | width, | ||
| int * | height | ||
| ) |
Definition at line 1540 of file movieclip.c.
References BKE_movieclip_get_ibuf(), MovieClipUser::framenr, height, IMB_freeImBuf(), MovieClip::lastframe, MovieClip::lastsize, real_ibuf_size(), width, ImBuf::x, and ImBuf::y.
Referenced by accessor_get_mask_for_track_callback(), autotrack_context_init_clips(), BKE_movieclip_get_size_fl(), BKE_movieclip_update_scopes(), BKE_tracking_refine_marker(), clip_graph_tracking_values_iterate_track_reprojection_error_values(), clip_graph_tracking_values_iterate_track_speed_values(), createTransTrackingCurvesData(), createTransTrackingData(), blender::compositor::PlaneTrackCommon::determineResolution(), blender::compositor::KeyingScreenOperation::determineResolution(), blender::compositor::MovieClipBaseOperation::determineResolution(), do_movie_proxy(), do_sequence_proxy(), draw_tracks_motion_and_error_curves(), ED_clip_point_undistorted_pos(), ED_space_clip_get_aspect_dimension_aware(), ED_space_clip_get_size(), followtrack_evaluate_using_2d_position(), image_camera_background_texture_get(), blender::compositor::MovieDistortionOperation::initExecution(), blender::compositor::TrackPositionOperation::initExecution(), marker_block_handler(), movieclip_load_get_size(), set_center_principal_exec(), solve_camera_freejob(), solve_camera_initjob(), uiTemplateMarker(), and uiTemplateMovieclipInformation().
| void BKE_movieclip_get_size_fl | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user, | ||
| float | size[2] | ||
| ) |
Definition at line 1573 of file movieclip.c.
References BKE_movieclip_get_size(), float(), height, size(), and width.
Referenced by BKE_mask_coord_from_movieclip(), BKE_mask_coord_to_movieclip(), and BKE_mask_point_parent_matrix_get().
| struct ImBuf* BKE_movieclip_get_stable_ibuf | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user, | ||
| float | loc[2], | ||
| float * | scale, | ||
| float * | angle, | ||
| int | postprocess_flag | ||
| ) |
Definition at line 1467 of file movieclip.c.
References angle(), MovieClipCache::angle, BKE_movieclip_get_postprocessed_ibuf(), MovieClip::cache, copy_v2_v2(), MovieTrackingStabilization::flag, MovieClipUser::framenr, get_stable_cached_frame(), IMB_freeImBuf(), MovieClipCache::loc, NULL, put_stabilized_frame_to_cache(), MovieClipCache::scale, MovieTracking::stabilization, MovieClipCache::stabilized, MovieClip::tracking, TRACKING_2D_STABILIZATION, and zero_v2().
Referenced by ED_space_clip_get_stable_buffer(), and seq_get_movieclip_ibuf().
| bool BKE_movieclip_has_cached_frame | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user | ||
| ) |
Definition at line 1972 of file movieclip.c.
References BLI_thread_lock(), BLI_thread_unlock(), MovieClip::flag, has_imbuf_cache(), and LOCK_MOVIECLIP.
Referenced by prefetch_find_uncached_frame(), and prefetch_movie_frame().
| bool BKE_movieclip_has_frame | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user | ||
| ) |
Definition at line 1528 of file movieclip.c.
References BKE_movieclip_get_ibuf(), and IMB_freeImBuf().
| bool BKE_movieclip_put_frame_if_possible | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user, | ||
| struct ImBuf * | ibuf | ||
| ) |
Definition at line 1983 of file movieclip.c.
References BLI_thread_lock(), BLI_thread_unlock(), MovieClip::flag, LOCK_MOVIECLIP, put_imbuf_cache(), and result.
Referenced by prefetch_movie_frame(), and prefetch_task_func().
Definition at line 1686 of file movieclip.c.
References detect_clip_source(), ListBase::first, free_buffers(), MovieClip::id, Scene::id, MovieClip::lastsize, movieclip_calc_length(), movieclip_load_get_size(), ID::next, Scene::nodetree, nodeUpdateID(), scene, and Main::scenes.
Referenced by movieclip_eval_update_reload(), and reload_exec().
Referenced by accessor_get_mask_for_track_callback(), accessor_get_preprocessed_ibuf(), BKE_autotrack_context_sync(), BKE_tracking_refine_marker(), BKE_tracking_track_get_weight_for_marker(), clip_draw_dopesheet_background(), clip_draw_dopesheet_main(), clip_graph_tracking_values_iterate_track_reprojection_error_values(), clip_graph_tracking_values_iterate_track_speed_values(), draw_frame_curves(), fetch_from_fcurve(), frame_jump_exec(), get_animated_weight(), libmv_tracks_new(), track_markers_endjob(), and tracking_context_get_frame_ibuf().
Referenced by autotrack_context_init_markers(), autotrack_is_track_trackable(), BKE_autotrack_context_finish(), BKE_autotrack_context_sync(), BKE_mask_point_parent_matrix_get(), blender::compositor::KeyingScreenOperation::buildVoronoiTriangulation(), camera_view3d_reconstruction(), camerasolver_evaluate(), blender::compositor::MovieClipNode::convertToOperations(), blender::compositor::KeyingScreenOperation::determineResolution(), ED_space_clip_get_clip_frame_number(), followtrack_context_init(), frame_jump_exec(), blender::compositor::MovieClipAttributeOperation::initExecution(), blender::compositor::TrackPositionOperation::initExecution(), marker_block_handler(), marker_update_cb(), objectsolver_evaluate(), blender::compositor::PlaneTrackCommon::readCornersFromTrack(), set_solver_keyframe_exec(), track_markers_initjob(), ui_numedit_but_TRACKPREVIEW(), uiTemplateMarker(), and uiTemplateMovieclipInformation().
| void BKE_movieclip_update_scopes | ( | struct MovieClip * | clip, |
| struct MovieClipUser * | user, | ||
| struct MovieClipScopes * | scopes | ||
| ) |
Definition at line 1712 of file movieclip.c.
References BKE_movieclip_get_ibuf(), BKE_movieclip_get_size(), BKE_movieclip_remap_scene_to_clip_frame(), BKE_tracking_get_search_imbuf(), BKE_tracking_marker_get(), BKE_tracking_marker_pattern_minmax(), BKE_tracking_track_get_active(), BKE_tracking_undistort_v2(), MovieTracking::camera, MovieTrackingMarker::flag, MovieTrackingTrack::flag, MovieClipScopes::frame_height, MovieClipScopes::frame_width, MovieClipUser::framenr, height, IMB_freeImBuf(), MovieClipScopes::marker, MARKER_DISABLED, MCLIP_PROXY_RENDER_UNDISTORT, NULL, MovieClipScopes::ok, MovieTrackingCamera::pixel_aspect, MovieTrackingMarker::pos, ImBuf::rect, ImBuf::rect_float, MovieClipUser::render_flag, MovieClipScopes::scene_framenr, MovieClipScopes::slide_scale, MovieClipScopes::track, MovieClipScopes::track_disabled, MovieClipScopes::track_locked, TRACK_LOCKED, MovieClipScopes::track_preview, TRACK_PREVIEW_ALPHA, MovieClipScopes::track_search, MovieClip::tracking, MovieClipScopes::undist_marker, MovieClipScopes::use_track_mask, width, ImBuf::x, and ImBuf::y.
Referenced by clip_properties_region_draw().
| void BKE_movieclip_user_set_frame | ( | struct MovieClipUser * | user, |
| int | framenr | ||
| ) |
Definition at line 1633 of file movieclip.c.
References MovieClipUser::framenr.
Referenced by accessor_get_mask_for_track_callback(), accessor_get_preprocessed_ibuf(), BKE_mask_point_parent_matrix_get(), blender::compositor::KeyingScreenOperation::buildVoronoiTriangulation(), clip_area_sync_frame_from_scene(), clip_refresh(), blender::compositor::PlaneTrackCommon::determineResolution(), blender::compositor::KeyingScreenOperation::determineResolution(), ED_clip_update_frame(), image_camera_background_texture_get(), blender::compositor::MovieClipBaseOperation::initExecution(), blender::compositor::MovieDistortionOperation::initExecution(), blender::compositor::TrackPositionOperation::initExecution(), and seq_render_movieclip_strip().