<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Mar 16, 2018 at 4:24 PM, <span dir="ltr"><<a href="mailto:aarthi@multicorewareinc.com" target="_blank">aarthi@multicorewareinc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"># HG changeset patch<br>
# User Aarthi Thirumalai <<a href="mailto:aarthi@multicorewareinc.com">aarthi@multicorewareinc.com</a>><br>
# Date 1521028474 -19800<br>
# Wed Mar 14 17:24:34 2018 +0530<br>
# Node ID 265d516af978a209bd22a6ae43487c<wbr>ecd01c4503<br>
# Parent d7c26df32fae052b7e895fee9bda1c<wbr>22b24cc44b<br>
Fix payload size for SEIRecoveryPoint<br>
<br>
diff -r d7c26df32fae -r 265d516af978 source/encoder/sei.cpp<br>
--- a/source/encoder/sei.cpp Tue Mar 13 13:40:13 2018 +0530<br>
+++ b/source/encoder/sei.cpp Wed Mar 14 17:24:34 2018 +0530<br>
@@ -41,8 +41,9 @@<br>
uint32_t type = m_payloadType;<br>
m_bitIf = &bs;<br>
BitCounter count;<br>
+ uint32_t payloadSize = m_payloadSize;<br>
bool hrdTypes = (m_payloadType == ACTIVE_PARAMETER_SETS || m_payloadType == PICTURE_TIMING || m_payloadType == BUFFERING_PERIOD);<br></blockquote><div><br></div><div>I think it is not required to check the condition "m_payloadType == RECOVERY_POINT" in other places</div><div>if you add this in above flag hrdTypes.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
- if (hrdTypes)<br>
+ if (hrdTypes || m_payloadType == RECOVERY_POINT)<br>
{<br>
m_bitIf = &count;<br>
/* virtual writeSEI method, write to bit counter to determine size */<br>
@@ -53,10 +54,10 @@<br>
WRITE_CODE(0xff, 8, "payload_type");<br>
}<br>
WRITE_CODE(type, 8, "payload_type");<br>
- uint32_t payloadSize;<br>
- if (hrdTypes || m_payloadType == USER_DATA_UNREGISTERED || m_payloadType == USER_DATA_REGISTERED_ITU_T_<wbr>T35)<br>
+ if (hrdTypes || m_payloadType == USER_DATA_UNREGISTERED || m_payloadType == USER_DATA_REGISTERED_ITU_T_T35 ||<br>
+ m_payloadType == RECOVERY_POINT)<br>
{<br>
- if (hrdTypes)<br>
+ if (hrdTypes || m_payloadType == RECOVERY_POINT)<br>
{<br>
X265_CHECK(0 == (count.getNumberOfWrittenBits(<wbr>) & 7), "payload unaligned\n");<br>
payloadSize = count.getNumberOfWrittenBits() >> 3;<br>
@@ -65,13 +66,10 @@<br>
payloadSize = m_payloadSize + 16;<br>
else<br>
payloadSize = m_payloadSize;<br>
-<br>
- for (; payloadSize >= 0xff; payloadSize -= 0xff)<br>
- WRITE_CODE(0xff, 8, "payload_size");<br>
- WRITE_CODE(payloadSize, 8, "payload_size");<br>
}<br>
- else<br>
- WRITE_CODE(m_payloadSize, 8, "payload_size");<br>
+ for (; payloadSize >= 0xff; payloadSize -= 0xff)<br>
+ WRITE_CODE(0xff, 8, "payload_size");<br>
+ WRITE_CODE(payloadSize, 8, "payload_size");<br>
/* virtual writeSEI method, write to bs */<br>
writeSEI(sps);<br>
}<br>
<br>______________________________<wbr>_________________<br>
x265-devel mailing list<br>
<a href="mailto:x265-devel@videolan.org">x265-devel@videolan.org</a><br>
<a href="https://mailman.videolan.org/listinfo/x265-devel" rel="noreferrer" target="_blank">https://mailman.videolan.org/<wbr>listinfo/x265-devel</a><br>
<br></blockquote></div><br></div></div>