Comments (26)
Problems solved
Add SignalToStop() method in DecoderContext.cs
call Signal ToStop() before Stop():
Video test:
fixed.mp4
from flyleaf.
from flyleaf.
from flyleaf.
player.Stop() requires re-opening. You use Stop as Pause? Do you get the error when you first time click Stop?
from flyleaf.
I am using player.Open(rtsp ur) on Play button and player.Stop() on Stop button:
from flyleaf.
@pubpy2015 You and your rtsp mess :) You try to Stop before it actually opened. that's the issue...
I knew that some locks are required during open/stop/dispose etc... I guess I will add them
from flyleaf.
I guess that was it, let me know if otherwise. I've not finished with locks yet, because I was planning to update Player.cs and Plugins but nice catch. I will need to come back on this one as Stop should ideally cancel previous Open for faster Stop.
from flyleaf.
One more thing. It's your responsibility to Stop the Player before Open. So generally, consider doing player.Stop(); also on your button1
from flyleaf.
I am trying on new code version. Better but it will make app hang in short time.
Sometime still error here:
Can you set player/demuxer status to Stopping and break open thread ?
from flyleaf.
Did you try to Stop before Open at button1?
from flyleaf.
No, if place Stop before Open, app will no crash but hang in more time.
If rtsp source is not available, you must wait more time before you can click Stop button.
Incase of app have multiple players, it is not convenient.
I am seeing you have DemuxInterrupt property and Stopping status. can you using this to break Open thread ?
from flyleaf.
What exactly are you doing? Pressing Open/Stop buttons all the time? I mean is this a real scenario or you just try hard to crash it?
from flyleaf.
I am doing an application like that:
each camera have 2 video streams, mainstream with higher resolution and substream with lower resolution.
In multiview mode, Flyleaf control will connect to substream of each camera.
when user double click to open camera1, application will stop substream of all cameras and open camera 1 with mainstream. Double click again will stop mainstream of camera1 and open substream of all cameras. => It will require open /stop continous in short time.
from flyleaf.
OK I think I've fixed the whole pyramid there of Start/Stop with also fast abort of opening
from flyleaf.
Yes, better performance but sometime still error here:
from flyleaf.
My first problem is that I cannot easily test this. The second problem is that I still believe that it's not the proper way of doing this. However, give it a try but consider finding a better way of implementing this?
from flyleaf.
@pubpy2015 Do you still have issues with this one, I will re-code some parts on version 3.2 (unfortunately not time for that currently).
from flyleaf.
Yes,
if rtsp source is ready, the problem here:
If rtsp source is not available, the problem here:
(you can try with any fake rtsp url, ex: rtsp://123.14.15.16:8554/live/c1234)
from flyleaf.
other problem is FlyLeaf control not redraw when resize:
from flyleaf.
What do you mean 'if rtsp source is ready' ?
The resize issue is for the designer only right?
from flyleaf.
What do you mean 'if rtsp source is ready' ?
this mean rtsp source 'online' and can play by player.
The resize issue is for the designer only right?
Yes.
from flyleaf.
Add below code in Flyleaf user control constructor will fix this problem:
// set double buffer
this.SetStyle(ControlStyles.UserPaint | ControlStyles.OptimizedDoubleBuffer | ControlStyles.AllPaintingInWmPaint | ControlStyles.SupportsTransparentBackColor, true);
from flyleaf.
Nice, sorry but didn't have time lately to help you out with this one. I will included it on the next update (I will review general start/stop and memory leaks)
from flyleaf.
Give another try with the latest version (3.1.9) and let me know if you still catch any crash!
from flyleaf.
It works well in most cases.
Very rarely does this error:
from flyleaf.
Nice should be also fixed
from flyleaf.
Related Issues (20)
- FlyleafHost causes stuck content in TabControl tab HOT 5
- WindowChrome's impact on layout
- FlyleafHost AspectRatio HOT 1
- Multi-UI Thread Support HOT 7
- Flyleafhost: Overlap & Transparency HOT 5
- There is a small black dot when FlyleafHost is initialized With Collapsed
- WinUI Memory Leak & Possible Fix HOT 1
- Overlays / Stats HOT 2
- Brilliant library, but I'm struggling with limited doco... HOT 12
- ShowFrame(0) does not work anymore in 3.7.42 HOT 3
- How can I tell if a file stream has a valid/playable audio and/or video stream? HOT 1
- Player.TogglePlayPause() doesn't restart from the pause point HOT 14
- Hello, may I ask how to play such data? HOT 2
- Unable to trap attempt to play an invalid video file HOT 3
- FlyLeaf libraries and DPI challenges HOT 7
- May I ask if it is possible to restore the function of resuming playback without reconnecting the old version after interrupting the stream? HOT 1
- System. AccessionViolationException when ShowFramePrev HOT 2
- When multiple players play the same file, the sound may be louder or softer HOT 1
- Play Delay HOT 1
- Play Delay HOT 9
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flyleaf.