OBS v28

Ideas, technical topics, help and discussion for ATV enthusiasts
Forum rules
This forum is run by the BATC (British Amateur Television Club), it is service made freely available to all interested parties, please do not abuse this privilege.

Thank you
Post Reply
G7JTT
Posts: 338
Joined: Fri Jun 10, 2016 5:05 pm

OBS v28

Post by G7JTT » Thu Sep 01, 2022 8:58 pm

Evening all OBS has a new version out (v28) but it is incompatible with the virtual camera plugin and SFX plugins. So untill these plugins especially the virtual camera, it's probably wise not to update if your using DATV easy or any other software that relies on the virtual camera plugin.

If you have installed v28 just reinstall v27 and all will be restored, at least that worked for me. Let's hope the plugin's catch up soon and new releases are published so we can update to v28

73 John G7JTT

g0mjw
Posts: 2353
Joined: Sat Sep 20, 2014 9:15 am

Re: OBS v28

Post by g0mjw » Thu Sep 01, 2022 9:34 pm

Thanks John,

Useful warning.

OBS has its own virtual camera, but when I queried this the developers didn't understand the need to virtual sound to go with it. I don't think they thought about it. My fear is the plugin development will stop now there is an official plugin.

Perhaps if a lot of us posted about this on the OBS forum it might happen as I expect it isn't a huge addition. What is really needed though is a DATV plugin for OBS that implements natively all those things we use the virtual camera and a script/DATVEasy to do and simply streams the data for the pluto. I don't know how to write an OBS plugin and don't have time to learn how at the moment. There is a Wiki https://obsproject.com/wiki/Getting-Sta ... evelopment and https://obsproject.com/docs/plugins.html

There is an example on the ffmpeg TS output https://github.com/obsproject/obs-studi ... mpeg-mux.c that may help. OBS record almost does what we need, but it doesn't pass all the parameters to the codec and multiplexer.

Mike

g0mjw
Posts: 2353
Joined: Sat Sep 20, 2014 9:15 am

Re: OBS v28

Post by g0mjw » Sun Sep 04, 2022 9:48 pm

Hi John

I have discovered a possible solution in DroidCam.https://github.com/dev47apps/droidcam-o ... ual-output

I didn't have my Nvidia PC to hand to test this so I am using hevc_qsv, the intel codec build into modern CPUs. It seems to be working fine with the intel codec on my laptop.

Note I have no idea what the optimum settings might be for the intel vs nvidia. I doubt it is as good but it comes for free. I just used the same ones which isn't likely to be right but surprisingly works.

c:\ffmpeg\bin\ffmpeg -f dshow -i video="DroidCam Video" -thread_queue_size 512 -f dshow -i audio="Microphone (DroidCam Audio)" -vcodec hevc_qsv -s 1280x720 -bf 0 -pix_fmt yuv420p -b:v 220k -r 15 -preset slow -profile:v main -rc cbr_hq -rc-lookahead 5 -acodec aac -aac_coder twoloop -ar 48000 -ac 1 -b:a 32k -f mpegts -muxrate 325k -streamid 0:256 -streamid 1:257 -metadata service_provider="G0MJW" -metadata service_name="Mike" -max_delay 2500000 -pcr_period 40 -pat_period 0.4 "udp://127.0.0.1:1234?pkt_size=1316"
Clipboard02.jpg
Clipboard02.jpg (1.12 MiB) Viewed 4775 times

g0mjw
Posts: 2353
Joined: Sat Sep 20, 2014 9:15 am

Re: OBS v28

Post by g0mjw » Mon Sep 05, 2022 3:24 pm

With a bit more thinking about it this worked better with the intel encoder, having removed some of the nvidia specific switches and also got the aspect ratio and resolution right.

c:\ffmpeg\bin\ffmpeg -f dshow -video_size 1280x720 -rtbufsize 100M -i video="DroidCam Video" -thread_queue_size 512 -f dshow -i audio="Microphone (DroidCam Audio)" -vcodec hevc_qsv -bf 0 -pix_fmt nv12 -b:v 220k -r 15 -preset slow -profile:v main -acodec aac -aac_coder twoloop -ar 48000 -ac 1 -b:a 32k -f mpegts -muxrate 325k -streamid 0:256 -streamid 1:257 -metadata service_provider="G0MJW" -metadata service_name="Mike" -max_delay 2500000 -pcr_period 40 -pat_period 0.4 "udp://127.0.0.1:1234?pkt_size=1316"

The bit -f dshow -video_size 1280x720 -rtbufsize 100M -i video="DroidCam Video" -thread_queue_size 512 -f dshow -i audio="Microphone (DroidCam Audio)"
and -pix_fmt nv12 covers the different input compared to virtualcam.

I experimented with the -rtbufsize figure, 100M seemed enough, it might be too much but most people have plenty of RAM. Increase it if not enough

Mike

F1EJP
Posts: 81
Joined: Wed Feb 24, 2021 2:46 pm

Re: OBS v28

Post by F1EJP » Wed Oct 05, 2022 10:37 pm

Hello,

The DroidCam Plugin outputs a frame rate of 29.97 fps even if OBS is set to 25 fps which causes problems to convert again to 25 fps
(2 conversions and jerky image)

For the moment I use the virtual camera integrated in OBS and DroidCam only for the sound !

73 Dominique F1EJP

g0mjw
Posts: 2353
Joined: Sat Sep 20, 2014 9:15 am

Re: OBS v28

Post by g0mjw » Thu Oct 06, 2022 7:10 am

Dominique,

You can request the frame rate when you call the input e.g. (-r 50). Just like a regular Webcam. I would suggest asking for 30 or 60 for 15 fps and 50 for 50 or 25. I mentioned to the author that if I request 15fps that works but the audio was broken. He had only tested 30/50/60. Set OBS to the same for best outcomes.

In practice setting OBS to 30 FPS and Droidcam to 30FPS works well for me as I use 15 FPS and just throw away every other frame. There is a trade off between FPS and image quality. Higher FPS is better with motion but worse with talking head type video we tend to use for QSOs. Running 1080p H265 in 333ks 2/3 or 3/4 tends to be better with lower frame rates. For higher bandwidths, then 25 or even 50 FPS is good.

Mike

Post Reply

Return to “General ATV Discussion”