Managing the tracks by a std::vector has been replaced with a std::map
mapping the track-number to a mkv_track_t.
This patch includes changing BlockFindTrackIndex to FindTrackByBlock,
keeping the same behaviour though using a more accurate name for the new
code.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Since indexing is now managed by matroska_segment_seeker.{hpp,cpp},
there is no need for the legacy functionality and data-members.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
It is quite obvious that we should append every Cluster as index, this
includes when doing work during Preload.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
If FAST_SEEK is enabled we can "preload" the location of all the
clusters when first opening our file in order to speed up seeking at a
later time.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Minor transformation from being a plain-old-data entity to a "proper"
C++ class where manual memory management has been removed and replaced
with std::string, as well as removal of unused members.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This code has been removed since it does not aid us in any way (besides
cluttering up the implementation with a data-member that we do not
really care about).
In the future we should respect the relevant matroska element, but
currently there is no point for us to care about it given the demuxers
overall state.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This variable is of no real aid, as such it has been removed to favor
readability. The less fuzz around what we actually need, the better.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Move list of supported MIME types from vlc.desktop.in to vlc.desktop.mimetypes,
with one mime type per line with the option of hash comments to associate
information with the MIME types.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
The MIME type is used by The Norwegian National Broadcasting company
(tv.nrk.no) when configuring it to run an external player.
Solves Debian bug #822245.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Tighter definition of int types, tightening of code, improved
change to type definition for win32 compilation
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This particular block as heen disabled for a long time, and the
rationale for disabling it with a preprocessor check is that it would
clogger the output during playback with a lot of unnecessary output.
Legacy code should be removed instead of disabled.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
- Moved variable declarations to a more narrow scope, there is no point
having them elsewhere (ParseAttachments).
- Introduced usage of EbmlTypeDispatcher in ParseChapters, both for
maintainability and performance reasons.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
These two functions did effectively the same thing, with the only
difference being the debug-dagnostic and the container modified.
This patch simply joins the two together by introducing a helper
function that will conditionally handle both Enter and Leave in terms of
the commands.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This function was unnecessary complex, shortened the code by introducing
a helper variable that we can use for direct indexing instead of going
through a switch-statement.
In the future we might want to revert this change, but since we will
always have values in the range [0, 4) I do not see a problem with
shortening the function this way.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This patch restores the correct virtual stop time of a chapter.
[ originally submitted by Denis Charmet ]
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
The previous static data-member really served no purpose, as such it has
been removed and been replaced by a more appropriate less-than operator
for EbmlProcessorEntry.
The static data-member caused issues when the module was compiled using msvc
(thanks for robux4 for finding the issue), which makes it even more important
for the patch to come into play.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>