Skip to content

Commit

Permalink
Fixes abst and abst-end values for frames element
Browse files Browse the repository at this point in the history
+ Update xsd

Signed-off-by: Maxime Gervais <[email protected]>
  • Loading branch information
g-maxime committed Jul 16, 2024
1 parent 4a8a8ea commit f95e65c
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 5 deletions.
14 changes: 9 additions & 5 deletions Source/Common/Output_Xml.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -577,12 +577,16 @@ return_value Output_Xml(ostream& Out, std::vector<file*>& PerFile, bitset<Option
}
}
{
auto AbstBf = abst_bf(File->PerFrame.back()->AbstBf);
if (AbstBf.HasAbsoluteTrackNumberValue())
auto FrameNumber = (PerChange_Next != File->PerChange.end() ? (*PerChange_Next)->FrameNumber : (MediaInfo_int64u)File->PerFrame.size())-1;
if (FrameNumber < File->PerFrame.size())
{
Text += " abst_end=\"";
Text += to_string(AbstBf.AbsoluteTrackNumber());
Text += '\"';
auto AbstBf = abst_bf(File->PerFrame[FrameNumber]->AbstBf);
if (AbstBf.HasAbsoluteTrackNumberValue())
{
Text += " abst_end=\"";
Text += to_string(AbstBf.AbsoluteTrackNumber());
Text += '\"';
}
}
}
if (Change->Width && Change->Height)
Expand Down
14 changes: 14 additions & 0 deletions tools/dvrescue.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,20 @@
</xsd:documentation>
</xsd:annotation>
</xsd:attribute>
<xsd:attribute name="abst" type="xsd:string">
<xsd:annotation>
<xsd:documentation xml:lang="en">
Absolute Timecode for start of sequence.
</xsd:documentation>
</xsd:annotation>
</xsd:attribute>
<xsd:attribute name="abst_end" type="xsd:string">
<xsd:annotation>
<xsd:documentation xml:lang="en">
Absolute Timecode of end of sequence.
</xsd:documentation>
</xsd:annotation>
</xsd:attribute>
<xsd:attribute name="size" type="sizeType"/>
<xsd:attribute name="pixel_format" type="pixel_formatType"/>
<xsd:attribute name="video_rate" type="video_rateType"/>
Expand Down

0 comments on commit f95e65c

Please sign in to comment.