71 if (ibuf !=
nullptr) {
106 printf(
"%s: property not found: %s.%s\n",
114 printf(
"%s: expected pointer property for %s.%s\n",
133 uiDefBut(block,
ButType::Label, 0,
IFACE_(
"File Path:"), 0, 19, 145, 19,
nullptr, 0, 0,
"");
135 row = &layout->
row(
false);
137 row = &
split->row(
true);
140 row->
op(
"clip.reload",
"", ICON_FILE_REFRESH);
157 printf(
"%s: property not found: %s.%s\n",
165 printf(
"%s: expected pointer property for %s.%s\n",
215#define B_MARKER_POS 3
216#define B_MARKER_OFFSET 4
217#define B_MARKER_PAT_DIM 5
218#define B_MARKER_SEARCH_POS 6
219#define B_MARKER_SEARCH_DIM 7
220#define B_MARKER_FLAG 8
290 float dim[2], pat_dim[2], pat_min[2], pat_max[2];
299 float scale_x = dim[0] / pat_dim[0];
300 float scale_y = dim[1] / pat_dim[1];
302 for (
int a = 0; a < 4; a++) {
312 float delta[2], side[2];
328 float dim[2], search_dim[2];
354 float offset[2], delta[2];
391 printf(
"%s: property not found: %s.%s\n",
399 printf(
"%s: expected pointer property for %s.%s\n",
428 tip =
TIP_(
"Marker is disabled at current frame");
431 tip =
TIP_(
"Marker is enabled at current frame");
461 IFACE_(
"Track is locked"),
474 float pat_min[2], pat_max[2];
475 float pat_dim[2], search_dim[2], search_pos[2];
502 tip =
TIP_(
"Marker is disabled at current frame");
505 tip =
TIP_(
"Marker is enabled at current frame");
525 block =
col->absolute_block();
551 TIP_(
"X-position of marker at frame in screen coordinates"));
565 TIP_(
"Y-position of marker at frame in screen coordinates"));
592 TIP_(
"X-offset to parenting point"));
606 TIP_(
"Y-offset to parenting point"));
633 TIP_(
"Width of marker's pattern in screen coordinates"));
647 TIP_(
"Height of marker's pattern in screen coordinates"));
674 TIP_(
"X-position of search at frame relative to marker's position"));
688 TIP_(
"Y-position of search at frame relative to marker's position"));
702 TIP_(
"Width of marker's search in screen coordinates"));
716 TIP_(
"Height of marker's search in screen coordinates"));
737 printf(
"%s: property not found: %s.%s\n",
745 printf(
"%s: expected pointer property for %s.%s\n",
796 if (clip->
anim !=
nullptr) {
808 col->label(
str, ICON_NONE);
812 if (framenr <= clip->
len) {
818 col->label(
str, ICON_NONE);
825 if (framenr <= clip->
len) {
835 col->label(
str, ICON_NONE);
SpaceClip * CTX_wm_space_clip(const bContext *C)
float BKE_movieclip_remap_scene_to_clip_frame(const struct MovieClip *clip, float framenr)
void BKE_movieclip_get_size(struct MovieClip *clip, const struct MovieClipUser *user, int *r_width, int *r_height)
void BKE_movieclip_filepath_for_frame(struct MovieClip *clip, const struct MovieClipUser *user, char *filepath)
struct ImBuf * BKE_movieclip_get_ibuf_flag(struct MovieClip *clip, const struct MovieClipUser *user, int flag, int cache_flag)
@ PANEL_TYPE_DEFAULT_CLOSED
struct MovieTrackingMarker * BKE_tracking_marker_ensure(struct MovieTrackingTrack *track, int framenr)
struct MovieTrackingMarker * BKE_tracking_marker_get(struct MovieTrackingTrack *track, int framenr)
void BKE_tracking_marker_clamp_search_position(struct MovieTrackingMarker *marker)
void BKE_tracking_marker_clamp_search_size(struct MovieTrackingMarker *marker)
void BKE_tracking_marker_pattern_minmax(const struct MovieTrackingMarker *marker, float min[2], float max[2])
void BLI_addtail(ListBase *listbase, void *vlink) ATTR_NONNULL(1)
MINLINE void sub_v2_v2(float r[2], const float a[2])
MINLINE void mul_v2_fl(float r[2], float f)
MINLINE void copy_v2_v2(float r[2], const float a[2])
MINLINE void add_v2_v2v2(float r[2], const float a[2], const float b[2])
MINLINE void sub_v2_v2v2(float r[2], const float a[2], const float b[2])
void void void const char * BLI_path_basename(const char *path) ATTR_NONNULL(1) ATTR_WARN_UNUSED_RESULT
#define SNPRINTF(dst, format,...)
#define SNPRINTF_UTF8(dst, format,...)
char size_t BLI_strncpy_utf8_rlen(char *__restrict dst, const char *__restrict src, size_t dst_maxncpy) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1
size_t BLI_snprintf_utf8_rlen(char *__restrict dst, size_t dst_maxncpy, const char *__restrict format,...) ATTR_NONNULL(1
#define STRNCPY_UTF8(dst, src)
#define BLT_I18NCONTEXT_DEFAULT_BPYRNA
void DEG_id_tag_update(ID *id, unsigned int flags)
bool ED_space_clip_poll(bContext *C)
ImBuf * ED_space_clip_get_buffer(const SpaceClip *sc)
void ED_region_image_metadata_panel_draw(ImBuf *ibuf, uiLayout *layout)
static void split(const char *text, const char *seps, char ***str, int *count)
void IMB_freeImBuf(ImBuf *ibuf)
Read Guarded memory(de)allocation.
uiBut * uiDefButF(uiBlock *block, ButType type, int retval, blender::StringRef str, int x, int y, short width, short height, float *poin, float min, float max, std::optional< blender::StringRef > tip)
uiBut * uiDefIconButBitI(uiBlock *block, ButType type, int bit, int retval, int icon, int x, int y, short width, short height, int *poin, float min, float max, std::optional< blender::StringRef > tip)
void UI_but_drawflag_enable(uiBut *but, int flag)
void UI_but_number_step_size_set(uiBut *but, float step_size)
void UI_block_func_handle_set(uiBlock *block, uiBlockHandleFunc func, void *arg)
uiBut * uiDefIconButI(uiBlock *block, ButType type, int retval, int icon, int x, int y, short width, short height, int *poin, float min, float max, std::optional< blender::StringRef > tip)
void uiTemplateID(uiLayout *layout, const bContext *C, PointerRNA *ptr, blender::StringRefNull propname, const char *newop, const char *openop, const char *unlinkop, int filter=UI_TEMPLATE_ID_FILTER_ALL, bool live_icon=false, std::optional< blender::StringRef > text=std::nullopt)
void UI_block_align_begin(uiBlock *block)
void UI_block_funcN_set(uiBlock *block, uiButHandleNFunc funcN, void *argN, void *arg2, uiButArgNFree func_argN_free_fn=MEM_freeN, uiButArgNCopy func_argN_copy_fn=MEM_dupallocN)
void UI_but_number_precision_set(uiBut *but, float precision)
void uiTemplateColorspaceSettings(uiLayout *layout, PointerRNA *ptr, blender::StringRefNull propname)
void UI_but_funcN_set(uiBut *but, uiButHandleNFunc funcN, void *argN, void *arg2, uiButArgNFree func_argN_free_fn=MEM_freeN, uiButArgNCopy func_argN_copy_fn=MEM_dupallocN)
uiBut * uiDefButBitI(uiBlock *block, ButType type, int bit, int retval, blender::StringRef str, int x, int y, short width, short height, int *poin, float min, float max, std::optional< blender::StringRef > tip)
uiBut * uiDefBut(uiBlock *block, uiButTypeWithPointerType but_and_ptr_type, int retval, blender::StringRef str, int x, int y, short width, short height, void *poin, float min, float max, std::optional< blender::StringRef > tip)
void UI_block_align_end(uiBlock *block)
constexpr const char * c_str() const
VecBase< float, D > step(VecOp< float, D >, VecOp< float, D >) RET
void * MEM_callocN(size_t len, const char *str)
void MEM_freeN(void *vmemh)
float MOV_get_fps(const MovieReader *anim)
PropertyRNA * RNA_struct_find_property(PointerRNA *ptr, const char *identifier)
PropertyType RNA_property_type(PropertyRNA *prop)
PointerRNA RNA_property_pointer_get(PointerRNA *ptr, PropertyRNA *prop)
const char * RNA_struct_identifier(const StructRNA *type)
ImBufFloatBuffer float_buffer
MovieTrackingMarker * marker
MovieTrackingTrack * track
float marker_search_pos[2]
struct MovieReader * anim
float pattern_corners[4][2]
MovieTrackingMarker * markers
void(* draw)(const bContext *C, Panel *panel)
char idname[BKE_ST_MAXNAME]
bool(* poll)(const bContext *C, PanelType *pt)
char translation_context[BKE_ST_MAXNAME]
char category[BKE_ST_MAXNAME]
char label[BKE_ST_MAXNAME]
uiBlock * absolute_block()
uiLayout & column(bool align)
void active_set(bool active)
void context_ptr_set(blender::StringRef name, const PointerRNA *ptr)
uiLayout & row(bool align)
uiLayout & split(float percentage, bool align)
PointerRNA op(wmOperatorType *ot, std::optional< blender::StringRef > name, int icon, blender::wm::OpCallContext context, eUI_Item_Flag flag)
void prop(PointerRNA *ptr, PropertyRNA *prop, int index, int value, eUI_Item_Flag flag, std::optional< blender::StringRef > name_opt, int icon, std::optional< blender::StringRef > placeholder=std::nullopt)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)