You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello. I am using this decoder to decode video stream coming from Janus WebRTC. Now, it works, that means, it receives frames and decodes them, but the problem is, i am getting very distorted images.
This is incoming stream configuration in Janus:
rtp-sample101: {
type = "rtp"
id = 101
description = "herelink"
metadata = "You can use this metadata section to put any info you want!"
audio = false
video = true
videoport = 5101
videopt = 96
videortpmap = "H264/90000"
secret = "adminpwd"
}
Now, i set up the ffmpeg endpoint to decode this incoming stream:
Mat imageMatrix = new Mat((int)height, (int)width, DepthType.Cv8U, 3);
imageMatrix.SetTo(sample);`
Image<Rgb, byte> image = imageMatrix.ToImage<Rgb, byte>();
Console.WriteLine("creating photo...");
image.Save($"MIS_{missionId}_photo_{photoCount + 1}.jpg");
The above code is implemented using Emgu.CV, I get following image no matter if i use Rgb or Bgr format, it is always distorted:
Now, i do not really know where is the problem. Is it a problem with incorrect format? Does ffmpeg need to include h264 library? or is this the problem with actual decoding?
The text was updated successfully, but these errors were encountered:
if ffmpeg doesnt complain, then it is most probably a problem with your usage of Emgu.CV and/or the source encoding (since you said the top part is correct).
if possible, try decoding locally at the the source, this means omit Janus, which i believe you had done.
since you use Janus, try receiving in web browser, i believe Janus has an example in this.
if the above example doesn't show the same "distorted" frames, then it is most likely some missed steps with using images in Emgu.CV, please open issue in Emgu.CV.
Hello. I am using this decoder to decode video stream coming from Janus WebRTC. Now, it works, that means, it receives frames and decodes them, but the problem is, i am getting very distorted images.
This is incoming stream configuration in Janus:
Now, i set up the ffmpeg endpoint to decode this incoming stream:
Then, i save this frame to file:
The above code is implemented using Emgu.CV, I get following image no matter if i use Rgb or Bgr format, it is always distorted:
Now, i do not really know where is the problem. Is it a problem with incorrect format? Does ffmpeg need to include h264 library? or is this the problem with actual decoding?
The text was updated successfully, but these errors were encountered: