hadi ahmed
Posts: 8
Joined: Sat Feb 28, 2015 9:20 pm

script for rca

Fri Mar 06, 2015 5:38 pm

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.

User avatar
DougieLawson
Posts: 38883
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: script for rca

Fri Mar 06, 2015 5:41 pm

You can control it with the tvservice command.
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

hadi ahmed
Posts: 8
Joined: Sat Feb 28, 2015 9:20 pm

Re: script for rca

Fri Mar 06, 2015 7:47 pm

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.

User avatar
rpdom
Posts: 17029
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: script for rca

Fri Mar 06, 2015 9:01 pm

You can't use RCA (composite) and HDMI output at the same time.

klricks
Posts: 7135
Joined: Sat Jan 12, 2013 3:01 am
Location: Grants Pass, OR, USA
Contact: Website

Re: script for rca

Sat Mar 07, 2015 1:49 am

Wait for the RPF to release the DSI display screen. From what I understand the RPi can have simultaneous output to HDMI and DSI.
Unless specified otherwise my response is based on the latest and fully updated RPiOS Buster w/ Desktop OS.

User avatar
rpdom
Posts: 17029
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: script for rca

Sat Mar 07, 2015 7:38 am

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+

hadi ahmed
Posts: 8
Joined: Sat Feb 28, 2015 9:20 pm

Re: script for rca

Sat Mar 07, 2015 8:44 pm

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.

User avatar
DougieLawson
Posts: 38883
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: script for rca

Sat Mar 07, 2015 10:11 pm

You can use the tvservice command to switch between RCA and HDMI and back again. No reboot needed.
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

User avatar
Burngate
Posts: 6290
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK Tralfamadore
Contact: Website

Re: script for rca

Sun Mar 08, 2015 12:09 pm

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?

drgeoff
Posts: 10676
Joined: Wed Jan 25, 2012 6:39 pm

Re: script for rca

Sun Mar 08, 2015 2:31 pm

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.

User avatar
Burngate
Posts: 6290
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK Tralfamadore
Contact: Website

Re: script for rca

Sun Mar 08, 2015 5:00 pm

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.

hadi ahmed
Posts: 8
Joined: Sat Feb 28, 2015 9:20 pm

Re: script for rca

Sun Mar 08, 2015 9:24 pm

IMG_2~1.jpg
IMG_2~1.jpg (43.05 KiB) Viewed 2485 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.

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13009
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: script for rca

Sun Mar 08, 2015 10:09 pm

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.

john.t
Posts: 28
Joined: Fri Sep 23, 2016 10:56 am

Re: script for rca

Tue Jun 20, 2017 10:44 am

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

User avatar
DougieLawson
Posts: 38883
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: script for rca

Tue Jun 20, 2017 11:36 pm

RTFManPage or RTFWebPage or run the command with no parameters to get crude help.
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

Return to “Advanced users”