Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

allow audio and video only streams #128

Closed

Conversation

DavidVentura
Copy link
Contributor

This addresses part of my performance related "bug" (#127).
It seems that removing the unnecessary streams + the unnecessary generation of videotestsrc and audiotestsrc that were fed to comply with the required caps helps a lot.

I added two options to the config audio_only and video_only, which are lists representing which sources do not have audio/video. These are optional and if not present the behavior stays the same as it was until now.

When trying to set an audio_only source as video, nothing happens, it will just render the background image if present (black if there's no background feed)

When trying to set a video_only source as audio, there's no audio at all.

PS: My personal config and motivation to do this:

sources=slides,cam1,cam2,audio1,audio2,video
audio_only=audio1,audio2
video_only=slides,cam1,cam2

I only get a mixed stream from video

@DavidVentura
Copy link
Contributor Author

new_caps.txt
old_caps.txt

I don't know of a service to upload diffs and github seems.. awkward for it.

(Only diffs)

    INFO Clock: Using System-Clock for all Pipelines: <Gst.SystemClock object at 0x7f98469b14c8    |	    INFO Clock: Using System-Clock for all Pipelines: <Gst.SystemClock object at 0x7f30cbcfc288 
    INFO VideoMix: Configuring VideoMixer for 3 Sources						   |	    INFO VideoMix: Configuring Mixer for 4 Sources
												   >	                intervideosrc channel=video_mic1_mixer !
												   >	                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio
												   >	                mix.
												   >	            
												   >	   DEBUG VideoMix: Reconfiguring Mixerpad 3 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1
    INFO AudioMix: Configuring Mixer for 3 Sources						   |	    INFO AudioMix: Configuring Mixer for 4 Sources
												   >	                interaudiosrc channel=audio_grabber_mixer !
												   >	                audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
												   >	                mix.
												   >	            
												   >	   DEBUG AudioMix: Setting Mixerpad 3 to volume=0.00
												   >	   DEBUG VideoMix: Reconfiguring Mixerpad 3 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1

(Diffs with context)

   DEBUG root: setting SIGINT handler									   DEBUG root: setting SIGINT handler
    INFO root: Python Version: sys.version_info(major=3, minor=5, micro=3, releaselevel='final',	    INFO root: Python Version: sys.version_info(major=3, minor=5, micro=3, releaselevel='final',
    INFO root: GStreamer Version: (major=1, minor=10, micro=3, nano=0)					    INFO root: GStreamer Version: (major=1, minor=10, micro=3, nano=0)
   DEBUG root: initializing Voctocore									   DEBUG root: initializing Voctocore
   DEBUG ConfigParser: considered config-files: 							   DEBUG ConfigParser: considered config-files: 
		/home/david/git/voctomix/voctocore/default-config.ini							/home/david/git/voctomix/voctocore/default-config.ini
		/home/david/git/voctomix/voctocore/config.ini								/home/david/git/voctomix/voctocore/config.ini
		/etc/voctomix/voctocore.ini										/etc/voctomix/voctocore.ini
		/etc/voctomix.ini											/etc/voctomix.ini
		/etc/voctocore.ini											/etc/voctocore.ini
		/home/david/.voctomix.ini										/home/david/.voctomix.ini
		/home/david/.voctocore.ini										/home/david/.voctocore.ini
   DEBUG ConfigParser: successfully parsed config-files: 						   DEBUG ConfigParser: successfully parsed config-files: 
		/home/david/git/voctomix/voctocore/default-config.ini							/home/david/git/voctomix/voctocore/default-config.ini
   DEBUG Clock: Obtaining System-Clock									   DEBUG Clock: Obtaining System-Clock
    INFO Clock: Using System-Clock for all Pipelines: <Gst.SystemClock object at 0x7f98469b14c8    |	    INFO Clock: Using System-Clock for all Pipelines: <Gst.SystemClock object at 0x7f30cbcfc288 
    INFO Clock: Starting NetTimeProvider on Port 9998							    INFO Clock: Starting NetTimeProvider on Port 9998
   DEBUG Voctocore: creating GObject-MainLoop								   DEBUG Voctocore: creating GObject-MainLoop
   DEBUG Voctocore: creating A/V-Pipeline								   DEBUG Voctocore: creating A/V-Pipeline
    INFO Pipeline: Video-Caps configured to: video/x-raw,format=I420,width=1920,height=1080,fram	    INFO Pipeline: Video-Caps configured to: video/x-raw,format=I420,width=1920,height=1080,fram
    INFO Pipeline: Audio-Caps configured to: audio/x-raw,format=S16LE,channels=2,layout=interlea	    INFO Pipeline: Audio-Caps configured to: audio/x-raw,format=S16LE,channels=2,layout=interlea
    INFO Pipeline: Creating 4 Creating AVSources: ['cam1', 'cam2', 'grabber', 'mic1']			    INFO Pipeline: Creating 4 Creating AVSources: ['cam1', 'cam2', 'grabber', 'mic1']
    INFO Pipeline: Creating AVSource cam1 at tcp-port 10000						    INFO Pipeline: Creating AVSource cam1 at tcp-port 10000
   DEBUG AVSource[cam1]: Binding to Source-Socket on [::]:10000						   DEBUG AVSource[cam1]: Binding to Source-Socket on [::]:10000
   DEBUG AVSource[cam1]: Setting GObject io-watch on Socket						   DEBUG AVSource[cam1]: Setting GObject io-watch on Socket
    INFO Pipeline: Creating Mirror-Output for AVSource cam1 at tcp-port 13000				    INFO Pipeline: Creating Mirror-Output for AVSource cam1 at tcp-port 13000
   DEBUG AVRawOutput[cam1_mirror]: Binding to Source-Socket on [::]:13000				   DEBUG AVRawOutput[cam1_mirror]: Binding to Source-Socket on [::]:13000
   DEBUG AVRawOutput[cam1_mirror]: Setting GObject io-watch on Socket					   DEBUG AVRawOutput[cam1_mirror]: Setting GObject io-watch on Socket
   DEBUG AVRawOutput[cam1_mirror]: Creating Output-Pipeline:						   DEBUG AVRawOutput[cam1_mirror]: Creating Output-Pipeline:

            intervideosrc channel=video_cam1_mirror !							            intervideosrc channel=video_cam1_mirror !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            queue !											            queue !
            mux.											            mux.

            interaudiosrc channel=audio_cam1_mirror !							            interaudiosrc channel=audio_cam1_mirror !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            queue !											            queue !
            mux.											            mux.

            matroskamux											            matroskamux
                name=mux										                name=mux
                streamable=true										                streamable=true
                writing-app=Voctomix-AVRawOutput !							                writing-app=Voctomix-AVRawOutput !

            multifdsink											            multifdsink
                blocksize=1048576									                blocksize=1048576
                buffers-max=500										                buffers-max=500
                sync-method=next-keyframe								                sync-method=next-keyframe
                name=fd											                name=fd
        												        
   DEBUG AVRawOutput[cam1_mirror]: Binding Error & End-of-Stream-Signal on Output-Pipeline		   DEBUG AVRawOutput[cam1_mirror]: Binding Error & End-of-Stream-Signal on Output-Pipeline
   DEBUG AVRawOutput[cam1_mirror]: Launching Output-Pipeline						   DEBUG AVRawOutput[cam1_mirror]: Launching Output-Pipeline
    INFO Pipeline: Creating AVSource cam2 at tcp-port 10001						    INFO Pipeline: Creating AVSource cam2 at tcp-port 10001
   DEBUG AVSource[cam2]: Binding to Source-Socket on [::]:10001						   DEBUG AVSource[cam2]: Binding to Source-Socket on [::]:10001
   DEBUG AVSource[cam2]: Setting GObject io-watch on Socket						   DEBUG AVSource[cam2]: Setting GObject io-watch on Socket
    INFO Pipeline: Creating Mirror-Output for AVSource cam2 at tcp-port 13001				    INFO Pipeline: Creating Mirror-Output for AVSource cam2 at tcp-port 13001
   DEBUG AVRawOutput[cam2_mirror]: Binding to Source-Socket on [::]:13001				   DEBUG AVRawOutput[cam2_mirror]: Binding to Source-Socket on [::]:13001
   DEBUG AVRawOutput[cam2_mirror]: Setting GObject io-watch on Socket					   DEBUG AVRawOutput[cam2_mirror]: Setting GObject io-watch on Socket
   DEBUG AVRawOutput[cam2_mirror]: Creating Output-Pipeline:						   DEBUG AVRawOutput[cam2_mirror]: Creating Output-Pipeline:

            intervideosrc channel=video_cam2_mirror !							            intervideosrc channel=video_cam2_mirror !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            queue !											            queue !
            mux.											            mux.

            interaudiosrc channel=audio_cam2_mirror !							            interaudiosrc channel=audio_cam2_mirror !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            queue !											            queue !
            mux.											            mux.

            matroskamux											            matroskamux
                name=mux										                name=mux
                streamable=true										                streamable=true
                writing-app=Voctomix-AVRawOutput !							                writing-app=Voctomix-AVRawOutput !

            multifdsink											            multifdsink
                blocksize=1048576									                blocksize=1048576
                buffers-max=500										                buffers-max=500
                sync-method=next-keyframe								                sync-method=next-keyframe
                name=fd											                name=fd
        												        
   DEBUG AVRawOutput[cam2_mirror]: Binding Error & End-of-Stream-Signal on Output-Pipeline		   DEBUG AVRawOutput[cam2_mirror]: Binding Error & End-of-Stream-Signal on Output-Pipeline
   DEBUG AVRawOutput[cam2_mirror]: Launching Output-Pipeline						   DEBUG AVRawOutput[cam2_mirror]: Launching Output-Pipeline
    INFO Pipeline: Creating AVSource grabber at tcp-port 10002						    INFO Pipeline: Creating AVSource grabber at tcp-port 10002
   DEBUG AVSource[grabber]: Binding to Source-Socket on [::]:10002					   DEBUG AVSource[grabber]: Binding to Source-Socket on [::]:10002
   DEBUG AVSource[grabber]: Setting GObject io-watch on Socket						   DEBUG AVSource[grabber]: Setting GObject io-watch on Socket
    INFO Pipeline: Creating Mirror-Output for AVSource grabber at tcp-port 13002			    INFO Pipeline: Creating Mirror-Output for AVSource grabber at tcp-port 13002
   DEBUG AVRawOutput[grabber_mirror]: Binding to Source-Socket on [::]:13002				   DEBUG AVRawOutput[grabber_mirror]: Binding to Source-Socket on [::]:13002
   DEBUG AVRawOutput[grabber_mirror]: Setting GObject io-watch on Socket				   DEBUG AVRawOutput[grabber_mirror]: Setting GObject io-watch on Socket
   DEBUG AVRawOutput[grabber_mirror]: Creating Output-Pipeline:						   DEBUG AVRawOutput[grabber_mirror]: Creating Output-Pipeline:

            intervideosrc channel=video_grabber_mirror !						            intervideosrc channel=video_grabber_mirror !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            queue !											            queue !
            mux.											            mux.

            interaudiosrc channel=audio_grabber_mirror !						            interaudiosrc channel=audio_grabber_mirror !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            queue !											            queue !
            mux.											            mux.

            matroskamux											            matroskamux
                name=mux										                name=mux
                streamable=true										                streamable=true
                writing-app=Voctomix-AVRawOutput !							                writing-app=Voctomix-AVRawOutput !

            multifdsink											            multifdsink
                blocksize=1048576									                blocksize=1048576
                buffers-max=500										                buffers-max=500
                sync-method=next-keyframe								                sync-method=next-keyframe
                name=fd											                name=fd
        												        
   DEBUG AVRawOutput[grabber_mirror]: Binding Error & End-of-Stream-Signal on Output-Pipeline		   DEBUG AVRawOutput[grabber_mirror]: Binding Error & End-of-Stream-Signal on Output-Pipeline
   DEBUG AVRawOutput[grabber_mirror]: Launching Output-Pipeline						   DEBUG AVRawOutput[grabber_mirror]: Launching Output-Pipeline
    INFO Pipeline: Creating AVSource mic1 at tcp-port 10003						    INFO Pipeline: Creating AVSource mic1 at tcp-port 10003
   DEBUG AVSource[mic1]: Binding to Source-Socket on [::]:10003						   DEBUG AVSource[mic1]: Binding to Source-Socket on [::]:10003
   DEBUG AVSource[mic1]: Setting GObject io-watch on Socket						   DEBUG AVSource[mic1]: Setting GObject io-watch on Socket
    INFO Pipeline: Creating Mirror-Output for AVSource mic1 at tcp-port 13003				    INFO Pipeline: Creating Mirror-Output for AVSource mic1 at tcp-port 13003
   DEBUG AVRawOutput[mic1_mirror]: Binding to Source-Socket on [::]:13003				   DEBUG AVRawOutput[mic1_mirror]: Binding to Source-Socket on [::]:13003
   DEBUG AVRawOutput[mic1_mirror]: Setting GObject io-watch on Socket					   DEBUG AVRawOutput[mic1_mirror]: Setting GObject io-watch on Socket
   DEBUG AVRawOutput[mic1_mirror]: Creating Output-Pipeline:						   DEBUG AVRawOutput[mic1_mirror]: Creating Output-Pipeline:

            intervideosrc channel=video_mic1_mirror !							            intervideosrc channel=video_mic1_mirror !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            queue !											            queue !
            mux.											            mux.

            interaudiosrc channel=audio_mic1_mirror !							            interaudiosrc channel=audio_mic1_mirror !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            queue !											            queue !
            mux.											            mux.

            matroskamux											            matroskamux
                name=mux										                name=mux
                streamable=true										                streamable=true
                writing-app=Voctomix-AVRawOutput !							                writing-app=Voctomix-AVRawOutput !

            multifdsink											            multifdsink
                blocksize=1048576									                blocksize=1048576
                buffers-max=500										                buffers-max=500
                sync-method=next-keyframe								                sync-method=next-keyframe
                name=fd											                name=fd
        												        
   DEBUG AVRawOutput[mic1_mirror]: Binding Error & End-of-Stream-Signal on Output-Pipeline		   DEBUG AVRawOutput[mic1_mirror]: Binding Error & End-of-Stream-Signal on Output-Pipeline
   DEBUG AVRawOutput[mic1_mirror]: Launching Output-Pipeline						   DEBUG AVRawOutput[mic1_mirror]: Launching Output-Pipeline
    INFO Pipeline: Creating Videmixer									    INFO Pipeline: Creating Videmixer
    INFO VideoMix: Configuring VideoMixer for 3 Sources						   |	    INFO VideoMix: Configuring Mixer for 4 Sources
   DEBUG VideoMix: Creating Mixing-Pipeline:								   DEBUG VideoMix: Creating Mixing-Pipeline:

            compositor name=mix !									            compositor name=mix !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            identity name=sig !										            identity name=sig !
            queue !											            queue !
            tee name=tee										            tee name=tee

            intervideosrc channel=video_background !							            intervideosrc channel=video_background !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            mix.											            mix.

            tee. ! queue ! intervideosink channel=video_mix_out						            tee. ! queue ! intervideosink channel=video_mix_out
        												        
                tee. ! queue ! intervideosink channel=video_mix_streamblanker				                tee. ! queue ! intervideosink channel=video_mix_streamblanker
            												            
                intervideosrc channel=video_cam1_mixer !						                intervideosrc channel=video_cam1_mixer !
                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio	                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio
                mix.											                mix.
            												            
                intervideosrc channel=video_cam2_mixer !						                intervideosrc channel=video_cam2_mixer !
                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio	                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio
                mix.											                mix.
            												            
                intervideosrc channel=video_grabber_mixer !						                intervideosrc channel=video_grabber_mixer !
                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio	                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio
                mix.											                mix.
            												            
												   >	                intervideosrc channel=video_mic1_mixer !
												   >	                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio
												   >	                mix.
												   >	            
   DEBUG VideoMix: Binding Error & End-of-Stream-Signal on Mixing-Pipeline				   DEBUG VideoMix: Binding Error & End-of-Stream-Signal on Mixing-Pipeline
   DEBUG VideoMix: Binding Handoff-Handler for Synchronus mixer manipulation				   DEBUG VideoMix: Binding Handoff-Handler for Synchronus mixer manipulation
   DEBUG VideoMix: Initializing Mixer-State								   DEBUG VideoMix: Initializing Mixer-State
    INFO VideoMix: Updating Mixer-State for Fullscreen-Composition					    INFO VideoMix: Updating Mixer-State for Fullscreen-Composition
   DEBUG VideoMix: Marking Pad-State as Dirty								   DEBUG VideoMix: Marking Pad-State as Dirty
   DEBUG VideoMix: Reconfiguring Mixerpad 0 to x/y=0/0, w/h=0/0 alpha=1.00, zorder=1			   DEBUG VideoMix: Reconfiguring Mixerpad 0 to x/y=0/0, w/h=0/0 alpha=1.00, zorder=1
   DEBUG VideoMix: Reconfiguring Mixerpad 1 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1			   DEBUG VideoMix: Reconfiguring Mixerpad 1 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1
   DEBUG VideoMix: Reconfiguring Mixerpad 2 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1			   DEBUG VideoMix: Reconfiguring Mixerpad 2 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1
												   >	   DEBUG VideoMix: Reconfiguring Mixerpad 3 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1
   DEBUG VideoMix: Launching Mixing-Pipeline								   DEBUG VideoMix: Launching Mixing-Pipeline
    INFO Pipeline: Creating Audiomixer									    INFO Pipeline: Creating Audiomixer
    INFO AudioMix: Configuring Mixer for 3 Sources						   |	    INFO AudioMix: Configuring Mixer for 4 Sources
   DEBUG AudioMix: Creating Mixing-Pipeline:								   DEBUG AudioMix: Creating Mixing-Pipeline:

            audiomixer name=mix !									            audiomixer name=mix !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            queue !											            queue !
            tee name=tee										            tee name=tee

            tee. ! queue ! interaudiosink channel=audio_mix_out						            tee. ! queue ! interaudiosink channel=audio_mix_out
        												        
                tee. ! queue ! interaudiosink channel=audio_mix_streamblanker				                tee. ! queue ! interaudiosink channel=audio_mix_streamblanker
            												            
                interaudiosrc channel=audio_cam1_mixer !						                interaudiosrc channel=audio_cam1_mixer !
                audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !			                audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
                mix.											                mix.
            												            
                interaudiosrc channel=audio_cam2_mixer !						                interaudiosrc channel=audio_cam2_mixer !
                audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !			                audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
                mix.											                mix.
            												            
												   >	                interaudiosrc channel=audio_grabber_mixer !
												   >	                audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
												   >	                mix.
												   >	            
                interaudiosrc channel=audio_mic1_mixer !						                interaudiosrc channel=audio_mic1_mixer !
                audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !			                audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
                mix.											                mix.
            												            
   DEBUG AudioMix: Binding Error & End-of-Stream-Signal on Mixing-Pipeline				   DEBUG AudioMix: Binding Error & End-of-Stream-Signal on Mixing-Pipeline
   DEBUG AudioMix: Initializing Mixer-State								   DEBUG AudioMix: Initializing Mixer-State
    INFO AudioMix: Updating Mixer-State									    INFO AudioMix: Updating Mixer-State
   DEBUG AudioMix: Setting Mixerpad 0 to volume=1.00							   DEBUG AudioMix: Setting Mixerpad 0 to volume=1.00
   DEBUG AudioMix: Setting Mixerpad 1 to volume=0.00							   DEBUG AudioMix: Setting Mixerpad 1 to volume=0.00
   DEBUG AudioMix: Setting Mixerpad 2 to volume=0.00							   DEBUG AudioMix: Setting Mixerpad 2 to volume=0.00
												   >	   DEBUG AudioMix: Setting Mixerpad 3 to volume=0.00
   DEBUG AudioMix: Launching Mixing-Pipeline								   DEBUG AudioMix: Launching Mixing-Pipeline
    INFO Pipeline: Creating Mixer-Background VSource at tcp-port 16000					    INFO Pipeline: Creating Mixer-Background VSource at tcp-port 16000
   DEBUG AVSource[background]: Binding to Source-Socket on [::]:16000					   DEBUG AVSource[background]: Binding to Source-Socket on [::]:16000
   DEBUG AVSource[background]: Setting GObject io-watch on Socket					   DEBUG AVSource[background]: Setting GObject io-watch on Socket
    INFO Pipeline: Creating Mixer-Output at tcp-port 11000						    INFO Pipeline: Creating Mixer-Output at tcp-port 11000
   DEBUG AVRawOutput[mix_out]: Binding to Source-Socket on [::]:11000					   DEBUG AVRawOutput[mix_out]: Binding to Source-Socket on [::]:11000
   DEBUG AVRawOutput[mix_out]: Setting GObject io-watch on Socket					   DEBUG AVRawOutput[mix_out]: Setting GObject io-watch on Socket
   DEBUG AVRawOutput[mix_out]: Creating Output-Pipeline:						   DEBUG AVRawOutput[mix_out]: Creating Output-Pipeline:

            intervideosrc channel=video_mix_out !							            intervideosrc channel=video_mix_out !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            queue !											            queue !
            mux.											            mux.

            interaudiosrc channel=audio_mix_out !							            interaudiosrc channel=audio_mix_out !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            queue !											            queue !
            mux.											            mux.

            matroskamux											            matroskamux
                name=mux										                name=mux
                streamable=true										                streamable=true
                writing-app=Voctomix-AVRawOutput !							                writing-app=Voctomix-AVRawOutput !

            multifdsink											            multifdsink
                blocksize=1048576									                blocksize=1048576
                buffers-max=10000									                buffers-max=10000
                sync-method=next-keyframe								                sync-method=next-keyframe
                name=fd											                name=fd
        												        
   DEBUG AVRawOutput[mix_out]: Binding Error & End-of-Stream-Signal on Output-Pipeline			   DEBUG AVRawOutput[mix_out]: Binding Error & End-of-Stream-Signal on Output-Pipeline
   DEBUG AVRawOutput[mix_out]: Launching Output-Pipeline						   DEBUG AVRawOutput[mix_out]: Launching Output-Pipeline
    INFO Pipeline: Creating StreamBlanker VSource pause at tcp-port 17000				    INFO Pipeline: Creating StreamBlanker VSource pause at tcp-port 17000
   DEBUG AVSource[pause_streamblanker]: Binding to Source-Socket on [::]:17000				   DEBUG AVSource[pause_streamblanker]: Binding to Source-Socket on [::]:17000
   DEBUG AVSource[pause_streamblanker]: Setting GObject io-watch on Socket				   DEBUG AVSource[pause_streamblanker]: Setting GObject io-watch on Socket
    INFO Pipeline: Creating StreamBlanker VSource nostream at tcp-port 17001				    INFO Pipeline: Creating StreamBlanker VSource nostream at tcp-port 17001
   DEBUG AVSource[nostream_streamblanker]: Binding to Source-Socket on [::]:17001			   DEBUG AVSource[nostream_streamblanker]: Binding to Source-Socket on [::]:17001
   DEBUG AVSource[nostream_streamblanker]: Setting GObject io-watch on Socket				   DEBUG AVSource[nostream_streamblanker]: Setting GObject io-watch on Socket
    INFO Pipeline: Creating StreamBlanker ASource at tcp-port 18000					    INFO Pipeline: Creating StreamBlanker ASource at tcp-port 18000
   DEBUG AVSource[streamblanker]: Binding to Source-Socket on [::]:18000				   DEBUG AVSource[streamblanker]: Binding to Source-Socket on [::]:18000
   DEBUG AVSource[streamblanker]: Setting GObject io-watch on Socket					   DEBUG AVSource[streamblanker]: Setting GObject io-watch on Socket
    INFO Pipeline: Creating StreamBlanker								    INFO Pipeline: Creating StreamBlanker
    INFO StreamBlanker: Configuring StreamBlanker video 2 Sources					    INFO StreamBlanker: Configuring StreamBlanker video 2 Sources
   DEBUG StreamBlanker: Creating Mixing-Pipeline:							   DEBUG StreamBlanker: Creating Mixing-Pipeline:

            compositor name=vmix !									            compositor name=vmix !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            queue !											            queue !
            intervideosink channel=video_streamblanker_out						            intervideosink channel=video_streamblanker_out

            audiomixer name=amix !									            audiomixer name=amix !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            queue !											            queue !
            interaudiosink channel=audio_streamblanker_out						            interaudiosink channel=audio_streamblanker_out


            intervideosrc channel=video_mix_streamblanker !						            intervideosrc channel=video_mix_streamblanker !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            vmix.											            vmix.

            interaudiosrc channel=audio_mix_streamblanker !						            interaudiosrc channel=audio_mix_streamblanker !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            amix.											            amix.


            interaudiosrc channel=audio_streamblanker !							            interaudiosrc channel=audio_streamblanker !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            amix.											            amix.
        												        
                intervideosrc channel=video_pause_streamblanker !					                intervideosrc channel=video_pause_streamblanker !
                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio	                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio
                vmix.											                vmix.
            												            
                intervideosrc channel=video_nostream_streamblanker !					                intervideosrc channel=video_nostream_streamblanker !
                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio	                video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio
                vmix.											                vmix.
            												            
   DEBUG StreamBlanker: Binding Error & End-of-Stream-Signal on Mixing-Pipeline				   DEBUG StreamBlanker: Binding Error & End-of-Stream-Signal on Mixing-Pipeline
   DEBUG StreamBlanker: Initializing Mixer-State							   DEBUG StreamBlanker: Initializing Mixer-State
   DEBUG StreamBlanker: Launching Mixing-Pipeline							   DEBUG StreamBlanker: Launching Mixing-Pipeline
    INFO Pipeline: Creating StreamBlanker-Output at tcp-port 15000					    INFO Pipeline: Creating StreamBlanker-Output at tcp-port 15000
   DEBUG AVRawOutput[streamblanker_out]: Binding to Source-Socket on [::]:15000				   DEBUG AVRawOutput[streamblanker_out]: Binding to Source-Socket on [::]:15000
   DEBUG AVRawOutput[streamblanker_out]: Setting GObject io-watch on Socket				   DEBUG AVRawOutput[streamblanker_out]: Setting GObject io-watch on Socket
   DEBUG AVRawOutput[streamblanker_out]: Creating Output-Pipeline:					   DEBUG AVRawOutput[streamblanker_out]: Creating Output-Pipeline:

            intervideosrc channel=video_streamblanker_out !						            intervideosrc channel=video_streamblanker_out !
            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1	            video/x-raw,format=I420,width=1920,height=1080,framerate=25/1,pixel-aspect-ratio=1/1
            queue !											            queue !
            mux.											            mux.

            interaudiosrc channel=audio_streamblanker_out !						            interaudiosrc channel=audio_streamblanker_out !
            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !				            audio/x-raw,format=S16LE,channels=2,layout=interleaved,rate=48000 !
            queue !											            queue !
            mux.											            mux.

            matroskamux											            matroskamux
                name=mux										                name=mux
                streamable=true										                streamable=true
                writing-app=Voctomix-AVRawOutput !							                writing-app=Voctomix-AVRawOutput !

            multifdsink											            multifdsink
                blocksize=1048576									                blocksize=1048576
                buffers-max=500										                buffers-max=500
                sync-method=next-keyframe								                sync-method=next-keyframe
                name=fd											                name=fd
        												        
   DEBUG AVRawOutput[streamblanker_out]: Binding Error & End-of-Stream-Signal on Output-Pipeline	   DEBUG AVRawOutput[streamblanker_out]: Binding Error & End-of-Stream-Signal on Output-Pipeline
   DEBUG AVRawOutput[streamblanker_out]: Launching Output-Pipeline					   DEBUG AVRawOutput[streamblanker_out]: Launching Output-Pipeline
   DEBUG Voctocore: creating ControlServer								   DEBUG Voctocore: creating ControlServer
   DEBUG ControlServer: Binding to Source-Socket on [::]:9999						   DEBUG ControlServer: Binding to Source-Socket on [::]:9999
   DEBUG ControlServer: Setting GObject io-watch on Socket						   DEBUG ControlServer: Setting GObject io-watch on Socket
   DEBUG root: running Voctocore									   DEBUG root: running Voctocore
    INFO Voctocore: running GObject-MainLoop								    INFO Voctocore: running GObject-MainLoop
   DEBUG VideoMix: [Streaming-Thread]: Pad-State is Dirty, applying new Mixer-State			   DEBUG VideoMix: [Streaming-Thread]: Pad-State is Dirty, applying new Mixer-State
   DEBUG VideoMix: Reconfiguring Mixerpad 0 to x/y=0/0, w/h=0/0 alpha=1.00, zorder=1			   DEBUG VideoMix: Reconfiguring Mixerpad 0 to x/y=0/0, w/h=0/0 alpha=1.00, zorder=1
   DEBUG VideoMix: Reconfiguring Mixerpad 1 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1			   DEBUG VideoMix: Reconfiguring Mixerpad 1 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1
   DEBUG VideoMix: Reconfiguring Mixerpad 2 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1			   DEBUG VideoMix: Reconfiguring Mixerpad 2 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1
												   >	   DEBUG VideoMix: Reconfiguring Mixerpad 3 to x/y=0/0, w/h=0/0 alpha=0.00, zorder=1
    INFO Voctocore: Terminated via Ctrl-C								    INFO Voctocore: Terminated via Ctrl-C

@Florob
Copy link
Contributor

Florob commented Jul 14, 2017

Thanks for working on this. In general I think audio and video only sources are a sensible concept.

However, I'm not sure how this patch is even working for you. It breaks the fundamental assumption that there is a bijection between source id and source name. With this patch applied videomix, audiomix and every thing else have three separate views on the source id.
In your setup in particular running set_audio audio1 will actually mute all channels, because it sets the audio to source id 3, but only sources 0 and 1 exist according to audiomix.
You are probably running set_audio 0, which is going to go away as per #98, or relying on changes made in #130.

Ideally this would also go along with voctogui changes so audio-only sources aren't offered as video inputs. More generally I'd want voctocore to report an error when setting a video input to a audio-only source and vice versa.

@DavidVentura
Copy link
Contributor Author

DavidVentura commented Jul 14, 2017 via email

@MaZderMind MaZderMind closed this Aug 13, 2017
@MaZderMind MaZderMind reopened this Aug 13, 2017
@MaZderMind
Copy link
Contributor

sorry, misread the title

@DavidVentura DavidVentura force-pushed the audio_video_only_streams branch from 93635c4 to 5e3989b Compare November 30, 2017 00:03
@DavidVentura
Copy link
Contributor Author

@Florob I'll try again and get this working. I "rebased" on top of master, with some changes.
My idea was to have VideoMix only know about streams that have video and AudioMix to know about the streams that have audio, this means that the commands may only display this sublists when querying about video_status and audio_status

Do you think this is the right approach? or would you approach this in some other way?

@MaZderMind
Copy link
Contributor

This PR has not seen any activity for a couple of months and is not mergable. As @Florob mentioned it is not really compatible with the current enumeration schema in the command line protocol.

@MaZderMind MaZderMind closed this Apr 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants