Log in or register to post comments

Avoid drawing or rendering video feed from camera

January 9, 2013 - 2:32pm #1

 

Hey there,

Really enjoying working with Vuforia so far. I haven't been able to find an answer or solution to one thing:

How can I not render the video feed from the camera in my scene? For app-specific reasons, I'd like to acquire and track targets as usual, but to *only* render the 3D content in my scene, on a black background — in other words, hiding (or not drawing / rendering) the video image from the camera being used for tracking.

This seems like a simple thing but I can't work out how to do it. I could draw a large black plane in my Unity scene to obscure it, but I'd rather not draw it in the first place, to save the processor cycles. I'd really appreciate any assistance you can offer.

I'm using Unity 4, but it would be useful to know this info for native apps as well.

Thanks very much!

Avoid drawing or rendering video feed from camera

September 22, 2015 - 1:03am #7

Avoid drawing or rendering video feed from camera

September 21, 2015 - 1:57am #6

Hello! I tried adding the script you recommended (with QCARRenderer.Instance.DrawVideoBackground = false) to ARCamera, but I keep getting the following error:

The name `QCARRenderer' does not exist in the current context

I tried "using Vuforia;" and "using Vuforia.QCARRenderer;" in the beginning of my script, but the error still won't go away. Can anyone tell me how to get past this error? Or has the solution to this problem changed? It's been a couple years since this solution was posted...

Thanks so much!

 

 

Hi, I would not touch the

January 14, 2013 - 4:27am #5

Hi, I would not touch the QCARBehaviour.cs (as this is part of the Qualcomm Augmented Reality scripts and should not be edited);

I would rather create a custom script, attach it to the ARCamera and call the function:

QCARRenderer.Instance.DrawVideoBackground = false

in the Start() method of it (alternatively, you can put it in the Update() function, just calling it once, i.e. only the first time the Update function is executed, i.e. using a boolean flag to check if it is the first time the Update is called).

 

Hi,   I am trying to do the

January 12, 2013 - 12:15pm #4

Hi,

 

I am trying to do the same!

 

In which script should I add this? I tried adding it to QCARBehaviour.cs at the end of the void: Start but I got this error: 

 

Assets/Plugins/Qualcomm Augmented Reality/Scripts/QCARBehaviour.cs(378,41): error CS0029: Cannot implicitly convert type `string' to `bool'
 

Indeed. Good to see you found

January 9, 2013 - 10:45pm #3

Indeed. Good to see you found the solution by yourself so quickly ;-)

Duh. "On start, turn off

January 9, 2013 - 2:47pm #2

Duh. "On start, turn off automatic video background rendering:QCARRenderer.Instance.DrawVideoBackground = false"

Log in or register to post comments