mirror of
https://github.com/badaix/snapcast.git
synced 2025-08-03 08:39:49 +02:00
encoder header is shared ptr
This commit is contained in:
parent
bfdca3038d
commit
d44232114a
7 changed files with 12 additions and 15 deletions
|
@ -56,8 +56,6 @@ public:
|
|||
|
||||
virtual ~Encoder()
|
||||
{
|
||||
if (headerChunk_ != NULL)
|
||||
delete headerChunk_;
|
||||
}
|
||||
|
||||
/// The listener will receive the encoded stream
|
||||
|
@ -86,7 +84,7 @@ public:
|
|||
}
|
||||
|
||||
/// Header information needed to decode the data
|
||||
virtual msg::Header* getHeader() const
|
||||
virtual std::shared_ptr<msg::Header> getHeader() const
|
||||
{
|
||||
return headerChunk_;
|
||||
}
|
||||
|
@ -95,7 +93,7 @@ protected:
|
|||
virtual void initEncoder() = 0;
|
||||
|
||||
SampleFormat sampleFormat_;
|
||||
msg::Header* headerChunk_;
|
||||
std::shared_ptr<msg::Header> headerChunk_;
|
||||
EncoderListener* listener_;
|
||||
std::string codecOptions_;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue