universe source can be set without setting data
This commit is contained in:
parent
2858d64218
commit
c58163fb8d
|
@ -42,16 +42,6 @@ UniverseSource::UniverseSource(std::shared_ptr<DATA::Pdu> pdu) {
|
|||
};
|
||||
|
||||
|
||||
/**
|
||||
Construct a new Universe.
|
||||
*/
|
||||
Universe::Universe()
|
||||
: DMX::Universe()
|
||||
{
|
||||
synchronized_ = false;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
Set universe data from a DMP PDU from a UniverseSource.
|
||||
*/
|
||||
|
@ -99,7 +89,17 @@ void Universe::set(std::shared_ptr<DMP::Pdu> dmp,
|
|||
/// The DMP Layer's Property values field is used to encode the
|
||||
// DMX512-A [DMX] START Code and data.
|
||||
DMX::Universe::set(pd);
|
||||
source_ = source;
|
||||
setSource(source);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @brief Universe::setSource
|
||||
* @param source
|
||||
*/
|
||||
void Universe::setSource(std::shared_ptr<UniverseSource> source)
|
||||
{
|
||||
source_ = source;
|
||||
}
|
||||
|
||||
}; // SACN
|
||||
|
|
|
@ -68,10 +68,11 @@ class Universe
|
|||
: public DMX::Universe
|
||||
{
|
||||
public:
|
||||
Universe();
|
||||
bool isSyncronized() const {return synchronized_;};
|
||||
Universe() : DMX::Universe(), synchronized_(false) {};
|
||||
const bool isSyncronized() const {return synchronized_;};
|
||||
|
||||
void set(std::shared_ptr<DMP::Pdu>, std::shared_ptr<UniverseSource>);
|
||||
void setSource(std::shared_ptr<UniverseSource>);
|
||||
|
||||
private:
|
||||
bool synchronized_;
|
||||
|
|
Loading…
Reference in New Issue