Code Monkey home page Code Monkey logo

Comments (6)

SuRGeoNix avatar SuRGeoNix commented on July 26, 2024
  1. Set Config.Player.AutoPlay = false
  2. You should either reset Config.Player.AutoPlay (on OpenCompleted) to true or Listen to Player.SeekCompleted and manually call Player.Play
  3. Listen to Player.OpenCompleted event and perform a Player.Seek

from flyleaf.

spektor56 avatar spektor56 commented on July 26, 2024

unfortunately it still plays the first part of the stream even with "Config.Player.AutoPlay = false"

from flyleaf.

SuRGeoNix avatar SuRGeoNix commented on July 26, 2024

I just retested to ensure AutoPlay=false works. Can you provide a log file?

from flyleaf.

spektor56 avatar spektor56 commented on July 26, 2024

Autoplay=false works, but when I set the position of the steam and then call play, the first half second of the beginning of the stream plays before it skips to the current stream position. I'm setting the position on the stream itself since it's a combination of raw hevc streams via ssh, so all I know is the length of the stream in bytes, not how long it is etc. Even with autoplay=false I'm assuming it's still buffering the data to play

from flyleaf.

SuRGeoNix avatar SuRGeoNix commented on July 26, 2024

I'm not sure yet how you use it, but the proper way and build-in way to seek will flush the packet queue after the seek has been completed and it will decode until the first video frame to present it. Did you check the (trace) logs? Does the demuxer brings old packets after seek?

from flyleaf.

spektor56 avatar spektor56 commented on July 26, 2024

rewind

This is an example of what is happening, I added some log output you can see. I can't use the player seek because i dont know the time in ms that i need to jump to, I only know the percentage. Its a raw HEVC stream over SSH so there is no information about current position / length in ms

[16:46:54 DBG] Opening New Stream
[16:46:54 DBG] Seeking to: 0%
[16:46:54 DBG] Stream Opened
[16:46:54 DBG] Seeking to: 63%
[16:46:54 DBG] Position Set to: 63%
[16:46:54 DBG] Calling Play
[16:46:54 DBG] Buffering Started - Current Stream Position:63%
[16:46:54 DBG] Buffering Complete - Current Stream Position:63%
[16:46:55 DBG] Buffering Started - Current Stream Position:63%
[16:46:55 DBG] Buffering Complete - Current Stream Position:63%

I am calling flush before i call play:

flyleafHost1.Player.Flush();
Serilog.Log.Debug("Calling Play");
flyleafHost1.Player.Play();

from flyleaf.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.