33#include "RNA_prototypes.hh"
59 float x,
float y,
bool sel,
float alpha,
uint pos_id,
uint color_id)
113 float strip[4], selected_strip[4];
116 uint keyframe_len = 0;
151 float color[4] = {0.0f, 0.0f, 0.0f, 0.3f};
164 for (
i = 0;
i < channel->tot_segment;
i++) {
166 channel->segments[2 *
i]);
168 channel->segments[2 *
i + 1]);
172 if (start_frame != end_frame) {
200 if (keyframe_len > 0) {
205 format,
"size", blender::gpu::VertAttrType::SFLOAT_32);
207 format,
"color", blender::gpu::VertAttrType::SFLOAT_32_32_32_32);
209 format,
"outlineColor", blender::gpu::VertAttrType::UNORM_8_8_8_8);
211 format,
"flags", blender::gpu::VertAttrType::UINT_32);
240 for (
i = 0;
i < channel->tot_segment;
i++) {
242 channel->segments[2 *
i]);
244 channel->segments[2 *
i + 1]);
246 if (start_frame != end_frame) {
364 float font_height =
BLF_height(fontid, channel->name,
sizeof(channel->name));
366 BLF_draw(fontid, channel->name, strlen(channel->name));
391 const int icon = (track->
flag &
TRACK_LOCKED) ? ICON_LOCKED : ICON_UNLOCKED;
ScrArea * CTX_wm_area(const bContext *C)
SpaceClip * CTX_wm_space_clip(const bContext *C)
float BKE_movieclip_remap_clip_to_scene_frame(const struct MovieClip *clip, float framenr)
void BLF_size(int fontid, float size)
float BLF_height(int fontid, const char *str, size_t str_len, ResultBLF *r_info=nullptr) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(2)
void BLF_draw(int fontid, const char *str, size_t str_len, ResultBLF *r_info=nullptr) ATTR_NONNULL(2)
void BLF_position(int fontid, float x, float y, float z)
#define LISTBASE_FOREACH(type, var, list)
void interp_v3_v3v3(float r[3], const float a[3], const float b[3], float t)
BLI_INLINE int BLI_rcti_size_y(const struct rcti *rct)
BLI_INLINE int BLI_rcti_size_x(const struct rcti *rct)
#define IN_RANGE(a, b, c)
MovieClip * ED_space_clip_get_clip(const SpaceClip *sc)
@ GPU_SHADER_KEYFRAME_SHAPE
@ GPU_SHADER_3D_UNIFORM_COLOR
void GPU_program_point_size(bool enable)
void GPU_blend(GPUBlend blend)
void UI_block_emboss_set(uiBlock *block, blender::ui::EmbossType emboss)
uiBlock * UI_block_begin(const bContext *C, ARegion *region, std::string name, blender::ui::EmbossType emboss)
const uiStyle * UI_style_get()
uiBut * uiDefIconButR_prop(uiBlock *block, ButType type, int retval, int icon, int x, int y, short width, short height, PointerRNA *ptr, PropertyRNA *prop, int index, float min, float max, std::optional< blender::StringRef > tip)
void UI_block_draw(const bContext *C, uiBlock *block)
void UI_block_end(const bContext *C, uiBlock *block)
void UI_GetThemeColor3fv(int colorid, float col[3])
@ TH_KEYTYPE_KEYFRAME_SELECT
void UI_GetThemeColor4fv(int colorid, float col[4])
void UI_FontThemeColor(int fontid, int colorid)
void UI_view2d_sync(bScreen *screen, ScrArea *area, View2D *v2dcur, int flag)
void UI_view2d_view_ortho(const View2D *v2d)
void ANIM_draw_previewrange(const Scene *scene, View2D *v2d, int end_frame_width)
void ANIM_draw_framerange(Scene *scene, View2D *v2d)
static void clip_draw_dopesheet_background(ARegion *region, MovieClip *clip, uint pos_id)
void clip_draw_dopesheet_channels(const bContext *C, ARegion *region)
void clip_draw_dopesheet_main(SpaceClip *sc, ARegion *region, Scene *scene)
static void draw_keyframe_shape(float x, float y, bool sel, float alpha, uint pos_id, uint color_id)
static void track_channel_color(MovieTrackingTrack *track, bool default_color, float color[3])
#define STRIP_HEIGHT_HALF
#define CHANNEL_HEIGHT_HALF
PropertyRNA * RNA_struct_type_find_property(StructRNA *srna, const char *identifier)
PointerRNA RNA_pointer_create_discrete(ID *id, StructRNA *type, void *data)
struct MovieTracking tracking
ListBase coverage_segments
MovieTrackingMarker * markers
MovieTrackingDopesheet dopesheet