Page 1 of 1

script for rca

Posted: Fri Mar 06, 2015 5:38 pm
by hadi ahmed
Hello.
my question is how to make a script on "opencv or otherwise" to control the RCA output in the raspberry pi B+,
i need to send a video to the RCA output within an application that i made with qt and opencv, "my purpose is to send just a video " .
thanks in advance.

Re: script for rca

Posted: Fri Mar 06, 2015 5:41 pm
by DougieLawson
You can control it with the tvservice command.

Re: script for rca

Posted: Fri Mar 06, 2015 7:47 pm
by hadi ahmed
Thanks DougieLawson.
I think i have been misunderstood, my question is not how to set RCA as an output to display raspberry window interface, but i need to know how to send just video frames " captured by a camera " to RCA port without losing control of the application seen on HDMI port.
ex : I have made an application based on opencv that do some process on a video but i need to send just that processed video to RCA port.
thanks a lot i appreciate your reply.

Re: script for rca

Posted: Fri Mar 06, 2015 9:01 pm
by rpdom
You can't use RCA (composite) and HDMI output at the same time.

Re: script for rca

Posted: Sat Mar 07, 2015 1:49 am
by klricks
Wait for the RPF to release the DSI display screen. From what I understand the RPi can have simultaneous output to HDMI and DSI.

Re: script for rca

Posted: Sat Mar 07, 2015 7:38 am
by rpdom
klricks wrote:Wait for the RPF to release the DSI display screen. From what I understand the RPi can have simultaneous output to HDMI and DSI.
and VGA with Gert's VGA666 adaptor, although all three at once might be too much for a A+/B+

Re: script for rca

Posted: Sat Mar 07, 2015 8:44 pm
by hadi ahmed
Thanks for your cooperation.
According to your reply, it becomes clear that the RCA port and HDMI output cannot be used at the same time, thus the only option is to sacrifice the use of HDMI, and only use the RCA. However, the problem that needs to be solved in this case, that the processed video cannot be displayed separately, it is displayed within the whole window.
the idea i pursue is to have the RPI boot up via RCA port to display the processed video separately. this is the point that needs to be tackled and solved with your help.
Thanks in advance.

Re: script for rca

Posted: Sat Mar 07, 2015 10:11 pm
by DougieLawson
You can use the tvservice command to switch between RCA and HDMI and back again. No reboot needed.

Re: script for rca

Posted: Sun Mar 08, 2015 12:09 pm
by Burngate
I may be barking up the wrong tree, here; if so feel free to ignore me.

You seem to want a video source to be displayed on a composite (PAL or NTSC) monitor, controlled by an application displayed on a different, possibly HDMI, monitor.
This is similar to an old-fashioned TV editing suite - the ones I used to play with had a Sony or similar controller with its own keyboard, monitor, etc. controlling the sources (one or more DVRs) the mixer and the destination (another DVR). At the very least there was a monitor showing what the recorder was receiving.

Cheaper options used the controller's monitor to show the recorder's output in a window, though that seems to me to be cheese-pairing.

So could you perhaps dedicate your present Pi to the RCA monitor, and use a second Pi connected to your HDMI monitor, controlling the first using SSH over a network connection?

Re: script for rca

Posted: Sun Mar 08, 2015 2:31 pm
by drgeoff
Burngate wrote:that seems to me to be cheese-pairing
No it is not. :)

But it might be 'cheeseparing' or 'cheese-paring' depending on which dictionary you use.

Re: script for rca

Posted: Sun Mar 08, 2015 5:00 pm
by Burngate
You're absolutely right. But it's too late now - changing it would look like I'm embarassed by my error. I am, but I don't want anyone to know that.

Besides, double-Gloucester goes well with mozzarella on pizza, and I can't see a reason for not comparing food with electronics.

Re: script for rca

Posted: Sun Mar 08, 2015 9:24 pm
by hadi ahmed
IMG_2~1.jpg
IMG_2~1.jpg (43.05 KiB) Viewed 2486 times
thanks everybody.
i think the only one who must be ignored is me, i think i didn't clarify the problem correctly.
please refer to the attached picture that will give you an idea about what i want to say.
i wrote a program based on opencv and c++ to do some process on a video, after compilation i ran the executable file and a window for the processed video is displayed, actually i need that window and only that window to be displayed through RCA output
as it is without any change " different scale, or expanding the window to full screen .... ".
for me the only thing that matter is the processed window, the final idea for me is to let RPI work as an embedded system that just process a video in somehow and send it via RCA.hope now the idea is clear and sorry for my bad English.

Re: script for rca

Posted: Sun Mar 08, 2015 10:09 pm
by mahjongg
The RCA output is simply a resampled version of the HDMI frame buffer, so the only way to only display the picture you want is to display it, and nothing but it on the desktop. So no if your demand is that the solution cannot be "expanding the window to full screen ...." then there is no way to do what you want.

Re: script for rca

Posted: Tue Jun 20, 2017 10:44 am
by john.t
DougieLawson wrote:You can use the tvservice command to switch between RCA and HDMI and back again. No reboot needed.
What commands do you need to type in order for this to work without the use of reboot?? ive tried it but sometimes my screen jus turn black when i switch to one or the other

Re: script for rca

Posted: Tue Jun 20, 2017 11:36 pm
by DougieLawson
RTFManPage or RTFWebPage or run the command with no parameters to get crude help.