Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FLV Video file restarts on seek #350

Closed
Noitarud opened this issue Aug 23, 2022 · 4 comments
Closed

FLV Video file restarts on seek #350

Noitarud opened this issue Aug 23, 2022 · 4 comments

Comments

@Noitarud
Copy link

Noitarud commented Aug 23, 2022

Tested first and second parts, updated player.
Player restarts play on a seek or when app gets focus back but the player's jump feature is still functional. VLC okay with it. It once flashed "error" at bottom (too fast to press"details". Do not know how to reproduce that, perhaps add button if there are errors - else show in the file info dialogue (that I see other users are asking for)).
Download here https://yah-tube.com/videos/rood/index.html

General
Complete name : …\solomons_laver_p1 (Sinai).flv
Format : Flash Video
File size : 185 MiB
Duration : 28mn 29s
Overall bit rate : 906 Kbps

Video
Format : AVC
Format/Info : Advanced Video Codec
Format profile : Main@L5.1
Format settings, CABAC : Yes
Format settings, ReFrames : 1 frame
Codec ID : 7
Duration : 28mn 29s
Bit rate : 800 Kbps
Width : 720 pixels
Height : 544 pixels
Display aspect ratio : 4:3
Frame rate mode : Constant
Frame rate : 29.970 fps
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Bits/(Pixel*Frame) : 0.068
Stream size : 163 MiB (88%)

Audio
Format : AAC
Format/Info : Advanced Audio Codec
Format profile : LC
Codec ID : 10
Duration : 28mn 29s
Bit rate : 64.0 Kbps
Channel count : 2 channels
Channel positions : Front: L R
Sampling rate : 44.1 KHz
Compression mode : Lossy
Stream size : 13.0 MiB (7%)

@moneytoo
Copy link
Owner

FLV is not seekable with ExoPlayer: https://exoplayer.dev/supported-formats.html

@Noitarud
Copy link
Author

Okay, its the parent program. Can close issue then. Still though, it is a defect.

I know it is possible to change the container using FFMPEG, you can tell all to use this command (which also works for damaged containers): …ffmpeg -i input.mp4 -c copy output.mp4

It is now seekable, This is how it appears:

General

Complete name : E:\solomons_laver_p1 (Sinai).mp4
Format : MPEG-4
Format profile : Base Media
Codec ID : isom
File size : 184 MiB
Duration : 28mn 29s
Overall bit rate : 904 Kbps
Writing application : Lavf55.44.100

Video
ID : 1
Format : AVC
Format/Info : Advanced Video Codec
Format profile : Main@L5.1
Format settings, CABAC : Yes
Format settings, ReFrames : 1 frame
Codec ID : avc1
Codec ID/Info : Advanced Video Coding
Duration : 28mn 29s
Bit rate : 806 Kbps
Width : 720 pixels
Height : 544 pixels
Display aspect ratio : 4:3
Frame rate mode : Variable
Frame rate : 29.970 fps
Minimum frame rate : 29.412 fps
Maximum frame rate : 30.303 fps
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Bits/(Pixel*Frame) : 0.069
Stream size : 164 MiB (89%)

Audio
ID : 2
Format : AAC
Format/Info : Advanced Audio Codec
Format profile : LC
Codec ID : 40
Duration : 28mn 29s
Bit rate mode : Constant
Bit rate : 89.1 Kbps
Channel count : 2 channels
Channel positions : Front: L R
Sampling rate : 44.1 KHz
Compression mode : Lossy
Stream size : 18.2 MiB (10%)

@Noitarud Noitarud changed the title Video file restarts on seek FLV Video file restarts on seek Aug 25, 2022
@Noitarud
Copy link
Author

If your claim is true, what is the difference between "app decoders" and "device decoders" and can't more/better/ improved/hacked decoders be used?

(This next solution is only proposed on the basis that it is a problem that keeps cropping up and something should be offered by the program)
Else, Maybe just pinpoint location in data by percentage and tell it to "just start" or identify typical features to find what part of frame that location is then estimate about where the frame starts/ends and then find actual start of this/next frame and begin… It doesn't matter how accurate it lands provided user does not need to be sent to the start! Only its a bit trivial for an outgoing format, and there's the solution above post, but this paragraph should help with incomplete files too (above post may work there too).

@Noitarud
Copy link
Author

Noitarud commented Oct 24, 2022

How about:

  • The "just start" idea? Seek by megabyte than by time?
  • Since it works with a little reprocessing (see my second post), can you treat the file as if the container was reprocessed? There apparently was not much to it so you could examine and keep the result in memory (perhaps save but some will highlight privacy)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants