Go to the documentation of this file.
6 #ifndef CNOID_UTIL_SEQ_H
7 #define CNOID_UTIL_SEQ_H
12 #include "exportdecl.h"
59 virtual std::shared_ptr<AbstractSeq>
cloneSeq()
const override {
60 return std::make_shared<SeqType>(*
this);
85 virtual void setNumFrames(
int n,
bool fillNewElements =
false)
override {
88 if(n > nold && nold > 0){
118 frame = (n > 0) ? (n - 1) : 0;
151 ElementType&
at(
int frameIndex) {
155 const ElementType&
at(
int frameIndex)
const {
171 const ElementType&
back()
const {
178 out_isValidRange =
false;
181 out_isValidRange =
false;
183 out_isValidRange =
true;
void clear()
Definition: Seq.h:98
ElementType & operator[](int frameIndex)
Definition: Seq.h:143
const std::string & seqType() const
Definition: AbstractSeq.h:36
double frameRate_
Definition: Seq.h:190
int frameOfTime(double time) const
Definition: Seq.h:110
int lastFrameOfTime(double time) const
Definition: Seq.h:114
SeqType & operator=(const SeqType &rhs)
Definition: Seq.h:39
virtual ElementType defaultValue() const
Definition: Seq.h:193
virtual void setOffsetTime(double time) override
Definition: Seq.h:131
const ElementType & front() const
Definition: Seq.h:163
virtual void setNumFrames(int n, bool fillNewElements=false) override
Definition: Seq.h:85
ElementType & at(int frameIndex)
Definition: Seq.h:151
ElementType value_type
Definition: Seq.h:21
virtual double getFrameRate() const override
Definition: Seq.h:69
Seq(const SeqType &org)
Definition: Seq.h:31
virtual AbstractSeq & operator=(const AbstractSeq &rhs) override
Definition: Seq.h:50
const ElementType & at(int frameIndex) const
Definition: Seq.h:155
const ElementType & operator[](int frameIndex) const
Definition: Seq.h:147
const ElementType & back() const
Definition: Seq.h:171
Seq(const char *seqType, int nFrames=0.0)
Definition: Seq.h:23
virtual int getNumFrames() const override
Definition: Seq.h:81
std::vector< ElementType > container
Definition: Seq.h:189
virtual void setFrameRate(double frameRate) override
Definition: Seq.h:73
double offsetTime_
Definition: Seq.h:191
virtual AbstractSeq & operator=(const AbstractSeq &rhs)
Definition: AbstractSeq.cpp:39
Definition: AbstractSceneLoader.h:11
ElementType & back()
Definition: Seq.h:167
bool empty() const
Definition: Seq.h:102
int offsetTimeFrame() const
Definition: Seq.h:135
Definition: AbstractSeq.h:21
int numFrames() const
Definition: Seq.h:77
virtual double getOffsetTime() const override
Definition: Seq.h:127
int clampFrameIndex(int frameIndex, bool &out_isValidRange)
Definition: Seq.h:175
static double defaultFrameRate()
Definition: AbstractSeq.cpp:72
void setOffsetTimeFrame(int offset)
Definition: Seq.h:139
ElementType & front()
Definition: Seq.h:159
double frameRate() const
Definition: Seq.h:65
virtual ~Seq()
Definition: Seq.h:63
double timeOfFrame(int frame) const
Definition: Seq.h:123
double timeLength() const
Definition: Seq.h:106
virtual std::shared_ptr< AbstractSeq > cloneSeq() const override
Definition: Seq.h:59