Lumiera
0.pre.04~rc.1
»edit your freedom«
Loading...
Searching...
No Matches
time-grid.hpp
Go to the documentation of this file.
1
/*
2
TIME-GRID.hpp - reference scale for quantised time
3
4
Copyright (C)
5
2010, Hermann Vosseler <Ichthyostega@web.de>
6
7
**Lumiera** is free software; you can redistribute it and/or modify it
8
under the terms of the GNU General Public License as published by the
9
Free Software Foundation; either version 2 of the License, or (at your
10
option) any later version. See the file COPYING for further details.
11
12
*/
13
14
39
#ifndef ASSET_META_TIME_GRID_H
40
#define ASSET_META_TIME_GRID_H
41
42
#include "
steam/asset/meta.hpp
"
43
#include "
lib/idi/entry-id.hpp
"
44
#include "
lib/time/grid.hpp
"
45
#include "
lib/time/timevalue.hpp
"
46
#include "
lib/symbol.hpp
"
47
48
49
50
namespace
steam
{
51
namespace
asset
{
52
namespace
meta {
53
54
using
lib::Symbol
;
55
using
lib::time::Time
;
56
using
lib::time::TimeVar
;
57
using
lib::time::TimeValue
;
58
using
lib::time::FrameRate
;
59
using
lib::time::FSecs
;
60
61
62
class
TimeGrid;
63
using
PGrid
=
lib::P<TimeGrid>
;
64
using
GridID
=
lib::idi::EntryID<TimeGrid>
;
65
66
77
class
TimeGrid
78
:
public
Meta
79
,
public
virtual
lib::time::Grid
80
{
81
public
:
82
/* === shortcut builder functions === */
83
static
PGrid
build
(
FrameRate
frames_per_second);
84
static
PGrid
build
(
Symbol
gridID,
FrameRate
frames_per_second);
85
static
PGrid
build
(
Symbol
gridID,
FrameRate
frames_per_second,
Time
origin);
86
87
protected
:
88
TimeGrid
(
GridID
const
&);
89
};
90
91
92
93
94
template
<>
95
struct
Builder
<
TimeGrid
>
96
{
97
string
id
;
98
99
FrameRate
fps
;
100
TimeVar
origin
;
101
107
lib::P<TimeGrid>
predecessor
;
108
114
Builder
(
string
const
& nameID =
""
)
115
: id {nameID}
116
, fps{1}
117
, origin{
TimeValue
(0)}
118
, predecessor{}
119
{ }
120
124
lib::P<TimeGrid>
commit();
125
126
};
127
128
}}}
// namespace steam::asset::meta
129
#endif
meta.hpp
Internal and organisational metadata.
lib::P
Customised refcounting smart pointer template, built upon std::shared_ptr, but forwarding type relati...
Definition
p.hpp:77
lib::Symbol
Token or Atom with distinct identity.
Definition
symbol.hpp:120
lib::time::FrameRate
Framerate specified as frames per second.
Definition
timevalue.hpp:670
lib::time::Grid
Abstraction of a value alignment grid.
Definition
grid.hpp:59
lib::time::TimeValue
basic constant internal time value.
Definition
timevalue.hpp:143
lib::time::TimeVar
a mutable time value, behaving like a plain number, allowing copy and re-accessing
Definition
timevalue.hpp:245
lib::time::Time
Lumiera's internal time value datatype.
Definition
timevalue.hpp:306
steam::asset::Meta
key abstraction: metadata, parametrisation, customisation and similar organisational traits.
Definition
asset/meta.hpp:112
steam::asset::meta::TimeGrid
Interface: a grid and scale definition for time quantisation.
Definition
time-grid.hpp:80
steam::asset::meta::TimeGrid::build
static PGrid build(FrameRate frames_per_second)
Definition
time-grid.cpp:157
entry-id.hpp
Bare symbolic and hash ID used for accounting of asset like entries.
grid.hpp
definition of a time grid abstraction for time and timecode handling.
lib::time::FSecs
boost::rational< int64_t > FSecs
rational representation of fractional seconds
Definition
timevalue.hpp:227
steam::asset::meta::Builder
Building and configuring a meta asset.
Definition
asset/meta.hpp:100
steam::asset
The asset subsystem of the Steam-Layer.
steam
Steam-Layer implementation namespace root.
lib::idi::EntryID
typed symbolic and hash ID for asset-like position accounting.
Definition
entry-id.hpp:219
steam::asset::meta::Builder< TimeGrid >::fps
FrameRate fps
Definition
time-grid.hpp:99
steam::asset::meta::Builder< TimeGrid >::predecessor
lib::P< TimeGrid > predecessor
when building a compound or variable grid, the predecessor is the grid active before the origin of th...
Definition
time-grid.hpp:107
steam::asset::meta::Builder< TimeGrid >::Builder
Builder(string const &nameID="")
initialise to blank (zero).
Definition
time-grid.hpp:114
steam::asset::meta::Builder< TimeGrid >::origin
TimeVar origin
Definition
time-grid.hpp:100
steam::asset::meta::Builder< TimeGrid >::id
string id
Definition
time-grid.hpp:97
symbol.hpp
Marker types to indicate a literal string and a Symbol.
timevalue.hpp
a family of time value like entities and their relationships.
steam
asset
meta
time-grid.hpp
Generated on Fri Nov 7 2025 for Lumiera by
1.9.8