4

I have Nikon D3300 camera and want to feed video output into my computer as part of live streaming with OBS.

I successfully installed v4l2loopback as well as gphoto2 on my Ubuntu 18.04. I already had ffmpeg installed. (Their all version information can be found at the bottom)

Then I execute the command gphoto2 --stdout --capture-movie | ffmpeg -i - -vcodec rawvideo -pix_fmt yuv420p -threads 0 -f v4l2 /dev/video2. I tested to see video output via guvcview and OBS. It shows video output properly but with one issue. It looks greenish like this (captured from OBS).

enter image description here

I also asked in v4l2loopback on github and developer pin-points that the problem is with the parameters feeding the program i.e. gphoto2 (or need some adjustment of parameters in ffmpeg too or not I'm not sure).

So do you know whether I use the right parameters? or else what's the right ones to solve this greenish video output.

haxpor
  • 209
  • 2
  • 11
  • The developer suggests primarily that: "..most likely these frames do not have any colourspace information, so you must pass the correct value to ffmpeg...". Looks like the relevant options are here: https://trac.ffmpeg.org/wiki/colorspace but I am out of my depth there :( – andrew.46 Apr 27 '19 at 07:05
  • @haxpor Show the complete log from your command. – llogan May 02 '19 at 17:45
  • sorry for late reply, I'll come back here for more logs of command. Because I put the camera back, and it needs some time to setup. – haxpor May 03 '19 at 10:46

0 Answers0