CArcTimelinePaint
- Module
- Arc
- Header
#include "Arc/Widgets/CArcTimelinePaint.h"- Namespace
Arcf
Public functions
| Returns | Name | Description |
|---|---|---|
float | RulerHeight | |
int32_t | MajorStep | The first of steps whose span reaches the design's major tick spacing, else fallback. |
int32_t | MinorDivisions | Minor ticks between two majors so they land about the design's minor spacing apart (1 = none). |
void | FrameTicks | Major and minor ticks for a frame view across rect, labelled in frames, seconds (frame / fps) or milliseconds. |
void | LinearTicks | Ticks for a continuous axis (ms, seconds) mapped linearly onto [x0, x1]: a 1/2/5 step that spaces majors at the design spacing. |
std::string | FormatLabel | |
void | Ruler | The ruler band: ticks rising from its bottom edge, labels in CodeSmall beside each major, the bottom border. |
void | TickGrid | A 1 px vertical line under each major tick across the track area. |
void | Playhead | The playhead: a 2 px AccentColor line over the whole area and its frame label centred on it inside the ruler band. |
void | Diamond | A filled diamond of bounding width extent centred on c. |
void | RowSeparator | A track row's bottom separator. |
void | Notify | A notify mark: the diamond on the row's centre line, its label beside it in Caption. |
void | StateBar | A notify state window: an 18 px Selection bar with its name. |
void | SyncMarker | A sync marker diamond in Success. |
void | WaveformBars | Waveform bars (2 px wide, 1 px apart) from peaks in [0, 1], centred on the lane's centre line; peaks are resampled to the lane width. |
Function details
RulerHeight
static float RulerHeight()MajorStep
static int32_t MajorStep(const int32_t* steps, size_t count, int32_t fallback, float frameWidth)The first of steps whose span reaches the design's major tick spacing, else fallback.
MinorDivisions
static int32_t MinorDivisions(float majorPx)Minor ticks between two majors so they land about the design's minor spacing apart (1 = none).
FrameTicks
static void FrameTicks(const FArcTimelineView& view, const ArcRect& rect, int32_t majorStep, EArcTimelineLabel label, float fps, std::vector<FArcRulerTick>& out)Major and minor ticks for a frame view across rect, labelled in frames, seconds (frame / fps) or milliseconds.
LinearTicks
static void LinearTicks(double from, double to, float x0, float x1, EArcTimelineLabel label, std::vector<FArcRulerTick>& out)Ticks for a continuous axis (ms, seconds) mapped linearly onto [x0, x1]: a 1/2/5 step that spaces majors at the design spacing.
FormatLabel
static std::string FormatLabel(double value, EArcTimelineLabel label, double step)Ruler
static void Ruler(CArcUIRenderer& renderer, const ArcRect& ruler, const std::vector<FArcRulerTick>& ticks, float opacity = 1.0f)The ruler band: ticks rising from its bottom edge, labels in CodeSmall beside each major, the bottom border.
TickGrid
static void TickGrid(CArcUIRenderer& renderer, const ArcRect& tracks, const std::vector<FArcRulerTick>& ticks, float opacity = 1.0f)A 1 px vertical line under each major tick across the track area.
Playhead
static void Playhead(CArcUIRenderer& renderer, const ArcRect& area, float rulerHeight, float x, const std::string& label, float opacity = 1.0f)The playhead: a 2 px AccentColor line over the whole area and its frame label centred on it inside the ruler band.
Diamond
static void Diamond(CArcUIRenderer& renderer, const ArcVec2& c, float extent, const ArcColor& color)A filled diamond of bounding width extent centred on c.
RowSeparator
static void RowSeparator(CArcUIRenderer& renderer, const ArcRect& row, float opacity = 1.0f)A track row's bottom separator.
Notify
static void Notify(CArcUIRenderer& renderer, const ArcRect& row, float x, const std::string& label, bool selected, float opacity = 1.0f)A notify mark: the diamond on the row's centre line, its label beside it in Caption.
StateBar
static void StateBar(CArcUIRenderer& renderer, const ArcRect& row, float x0, float x1, const std::string& label, bool selected, float opacity = 1.0f)A notify state window: an 18 px Selection bar with its name.
SyncMarker
static void SyncMarker(CArcUIRenderer& renderer, const ArcRect& row, float x, float opacity = 1.0f)A sync marker diamond in Success.
WaveformBars
static void WaveformBars(CArcUIRenderer& renderer, const ArcRect& lane, const float* peaks, size_t count, const ArcColor& color)Waveform bars (2 px wide, 1 px apart) from peaks in [0, 1], centred on the lane's centre line; peaks are resampled to the lane width.