Mercurial > mplayer.hg
comparison DOCS/tech/nut.txt @ 20965:a8651041ba2b
seeking
author | michael |
---|---|
date | Fri, 17 Nov 2006 12:44:10 +0000 |
parents | eb8927d75bcd |
children | dc1a02e98cb6 |
comparison
equal
deleted
inserted
replaced
20964:eb8927d75bcd | 20965:a8651041ba2b |
---|---|
899 in the absence of a valid header at the beginning, players SHOULD search for | 899 in the absence of a valid header at the beginning, players SHOULD search for |
900 backup headers starting at offset 2^x; for each x players SHOULD end their | 900 backup headers starting at offset 2^x; for each x players SHOULD end their |
901 search at a particular offset when any startcode is found (including syncpoint) | 901 search at a particular offset when any startcode is found (including syncpoint) |
902 | 902 |
903 | 903 |
904 Seeking without an index (non-normative): | |
905 ----------------------------------------- | |
906 A. backward seeking | |
907 1. perform a binary search on the syncpoint timestamps finding the one | |
908 which is largest and <= the target timestamp | |
909 B. forward seeking | |
910 1a. perform a binary search on the syncpoint timestamps finding the one | |
911 which is smallest and >= the target timestamp | |
912 1b. perform a binary search on the syncpoint back pointers finding the | |
913 smallest one which has a back ptr >= the position of what was found in 1. | |
914 2. follow the back pointer to the correspoding syncpoint | |
915 | |
916 Seeking with an index (non-normative): | |
917 -------------------------------------- | |
918 The demuxer only has to find the appropriate keyframe in the index and | |
919 start demuxing from the previous syncpoint | |
920 | |
921 Note, more complicated seeking methods exist which are capable of quickly | |
922 seeking to the optimal point in the presence of an index even if only a | |
923 subset of all streams are active but a muxer SHOULD place syncpoints, | |
924 and keyframes if it can affect the placement of keyframes so that simple | |
925 low complexity seeking works with fine granularity | |
926 | |
904 | 927 |
905 Semantic requirements: | 928 Semantic requirements: |
906 ====================== | 929 ====================== |
907 | 930 |
908 If more than one stream of a given stream class is present, each one SHOULD | 931 If more than one stream of a given stream class is present, each one SHOULD |