Skip to main content
16 events
when toggle format what by license comment
2 days ago comment added Rotem @Pavel I tried to encode MJPEG over RTSP, and it looks like there are limitations. Execute mediamtx.exe, then encode synthetic pattern (for testing): ffmpeg -f lavfi -i testsrc=size=640x480:rate=30 -vcodec mjpeg -huffman 0 -force_duplicated_matrix 1 -pix_fmt yuvj420p -f rtsp rtsp://localhost:8554/camera01. Then play VLC network: rtsp://@127.0.0.1:8554/camera01 (it's working). As you can see, I had to add the arguments -huffman 0 -force_duplicated_matrix 1 -pix_fmt yuvj420p to the MJPEG encoder. I don't no if the yuvj422 MJPEG from your camera can work with RTSP without re-encoding.
2 days ago comment added Pavel @Rotem When playing recorded mp4, it's OK
Jul 2 at 16:20 comment added Rotem When playing the recorded MP4 file, is it OK, or green? Try just: ffmpeg -f dshow -s 640x480 -i video="Integrated Webcam" -vcodec copy -t 10 output.mp4 you may also try: ffmpeg -f dshow -vcodec mjpeg -s 640x480 -i video="Integrated Webcam" -vcodec copy -t 10 output.mp4 (I saw that -input_format is not working with dshow, and the way for selecting MJPEG is adding -vcodec mjpeg before -i).
Jul 2 at 11:58 history edited Giacomo1968 CC BY-SA 4.0
Inline image and removing casual stuff; not needed.
Jul 2 at 11:38 comment added Pavel @LPChip up with ffplay output
Jul 2 at 11:38 history edited Pavel CC BY-SA 4.0
added 4655 characters in body
Jul 2 at 11:12 comment added LPChip Do note, VLC has build-in codecs, it does not use codecs that are actually present in your system. You can try a different player, and you can try a different codec that is standard to rule out codec vs player.
Jul 2 at 10:57 comment added Pavel @LPChip thanks for participating in my problem. I added information about the codec that vlc displays in the start topic. I don't know how else to check if the codec is correct or not
Jul 2 at 10:55 history edited Pavel CC BY-SA 4.0
added 54 characters in body; edited tags
Jul 2 at 10:42 comment added Pavel @Rotem output: Input #0, dshow, from 'video=Integrated Webcam': Stream #0:0: Video: mjpeg (Baseline) (MJPG / 0x47504A4D), yuvj422p(pc, bt470bg/unknown/unknown), 640x480, 30 fps, 30 tbr, 10000k tbn encoder : Lavf60.16.100 Stream #0:0: Video: mjpeg (Baseline) (mp4v / 0x7634706D), yuvj422p(pc, bt470bg/unknown/unknown), 640x480, q=2-31, 30 fps, 30 tbr, 10000k tbn [out#0/mp4 @ 000001ebef28fb00] video:13877kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.031674% size= 13882kB time=00:00:09.96 bitrate=11408.3kbits/s
Jul 2 at 10:36 comment added LPChip @Pavel it can still be an issue, but it might be that it just encodes the video with a codec that is non-existent. I just said what the green screen means. So check that you are actually encoding with the right codec
Jul 2 at 10:33 comment added Pavel @LPChip unfortunately, apparently, this is not my option. VLC is now running on the same host and under the same user as the mediamtx server
Jul 1 at 16:31 comment added Rotem Is it working with output file instead of RTSP: ffmpeg -hwaccel_output_format qsv -fflags nobuffer -f dshow -vcodec mjpeg_qsv -s 640x480 -i video="Integrated Webcam" -vcodec copy -t 10 output.mp4 for example? Instead of -hwaccel_output_format qsv -vcodec mjpeg_qsv, try: -input_format mjpeg. Since you are using stream copy: -vcodec copy, the camera output suppose to be MJPEG encoded video stream.
Jul 1 at 9:04 comment added LPChip A green screen often means its missing a codec on the device playing the video/stream.
S Jul 1 at 8:59 review First questions
Jul 1 at 9:13
S Jul 1 at 8:59 history asked Pavel CC BY-SA 4.0