Comments (10)
是在播放同一个视频的时候,会一直发生Video has been updated 吗?这个是不合理的
from ksplayer.
from ksplayer.
你是重载updateVideo(refreshRate: Float, formatDescription: CMFormatDescription?) 这个方法吗?
from ksplayer.
试着用AVDisplayCriteria(refreshRate: refreshRate, videoDynamicRange: videoDynamicRange.rawValue) 这给初始化方法,不要用 AVDisplayCriteria(refreshRate: refreshRate, formatDescription: formatDescription) 这个初始化方法
from ksplayer.
from ksplayer.
你试着这样重载。看行不行
override func updateVideo(refreshRate: Float, formatDescription: CMFormatDescription?) {
#if os(tvOS) || os(xrOS)
guard let displayManager = UIApplication.shared.windows.first?.avDisplayManager,
displayManager.isDisplayCriteriaMatchingEnabled,
!displayManager.isDisplayModeSwitchInProgress
else {
return
}
if let formatDescription {
displayManager.preferredDisplayCriteria = AVDisplayCriteria(refreshRate: refreshRate, videoDynamicRange: formatDescription.dynamicRange.rawValue)
}
#endif
}
from ksplayer.
from ksplayer.
I tried even using
displayManager.preferredDisplayCriteria = AVDisplayCriteria(refreshRate: refreshRate, videoDynamicRange: formatDescription.dynamicRange.rawValue)
with the video output, with no success.
from ksplayer.
I have the impression that live refresh rate less than 50, works with:
AVDisplayCriteria(refreshRate: track.nominalFrameRate, videoDynamicRange: videoDynamicRange)
and that for 50 or more, works with the new tvOS17 API.
UPDATE:
nope, it's mixed behavior even in this case
from ksplayer.
So for 50 fps I use this:
displayManager.preferredDisplayCriteria = AVDisplayCriteria(refreshRate: videoOutputRefreshRate, formatDescription: videoOutputFormatDescription)
and it works.
For 25 fps most of the time doesn't work well with any approach.
from ksplayer.
Related Issues (20)
- 关于滤镜的问题 HOT 17
- 播放多音轨视频出错 HOT 6
- 播放8K视频出现系统杀进程问题 HOT 13
- 关于边下边播,缓存本地。 HOT 3
- 是否可以增加缓冲时长的功能? HOT 5
- 你好 我是个菜鸟 请问一下 想要添加字幕的话 应该如何用呢 HOT 5
- Video player does not take into account dynamic metadata on HOT 13
- Player opens then instantly closes
- A Considerate Appeal for Fair Pricing of Ksplayer's Commercial License HOT 2
- Using GPL license
- How can I write a UDP connection in Swiftui HOT 21
- 能否在外部控制显示、关闭字幕; HOT 1
- Disable audio HOT 1
- Network Error State Not Triggered During Live Stream HOT 10
- RTSP video is not shown when using slow connection HOT 2
- EIA-608 and CTA-708 Captions HOT 4
- Picture in Picture (PiP) on tvOS HOT 6
- Demo project not working on visionOS 1.1 / iOS 17.4 simulators - libharfbuzz.framework HOT 2
- iOS13 dyld: Library not loaded: /usr/lib/libexpat.1.dylib HOT 2
- Whisper CPP HOT 3
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 ksplayer.