Commit 8a432c9b authored by Max Kellermann's avatar Max Kellermann

decoder/mad: move code to LoadNextFrame()

parent 187204f0
......@@ -207,6 +207,8 @@ private:
*/
bool HandleCurrentFrame() noexcept;
bool LoadNextFrame() noexcept;
bool Read() noexcept;
};
......@@ -965,11 +967,8 @@ MadDecoder::HandleCurrentFrame() noexcept
}
inline bool
MadDecoder::Read() noexcept
MadDecoder::LoadNextFrame() noexcept
{
if (!HandleCurrentFrame())
return false;
while (true) {
MadDecoderAction ret;
do {
......@@ -999,6 +998,13 @@ MadDecoder::Read() noexcept
}
}
inline bool
MadDecoder::Read() noexcept
{
return HandleCurrentFrame() &&
LoadNextFrame();
}
inline void
MadDecoder::RunDecoder() noexcept
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment