[Bug 793118] frames are pixelated/blurred on ios
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Mon Feb 5 15:42:02 UTC 2018
https://bugzilla.gnome.org/show_bug.cgi?id=793118
--- Comment #1 from Muhammet Ilendemli <mi at tailored-apps.com> ---
A workround for the issue:
Create a subclass of CAEAGLLayer and override the frame attribute to return a
scaled version of your screen' bounds
class CustomLayer: CAEAGLLayer {
override var frame: CGRect {
set { }
get {
let transform = CGAffineTransform(scaleX: 6, y: 6)
return UIScreen.main.bounds.applying(transform)
}
}
}
6 because:
i have an iPhone 6, so the screen width is 320. ergo stream gets resized to
320x180
the video is an 1080p rtsp stream (i think) from eathcam.com
1920/320 = 6 or 1080/180 = 6
set the contentScaleFactor to 6 aswell, because reasons, and use your subclass
of CAEAGLLayer:
class EAGLView: UIView {
override class var layerClass: AnyClass {
return CustomLayer.self
}
override init(frame: CGRect) {
super.init(frame: frame)
contentScaleFactor = 6
}
required init?(coder aDecoder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
}
any 1080p stream should be clear now.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list