I'd like to stream the output of two cameras to a separate process. Right now, it looks like the best way to do that is to grab the rendered camera views from the screen via platform specific screen capture hooks then compress them real time with h.264. Is there a way to grab the input of the cameras within unity and avoid rendering them to the screen?

One solution I'm considering involves using Unity's multiplayer capability to run the game on a separate machine and grab it from that screen buffer, unbeknownst to the player.

  • 4
    \$\begingroup\$ You're throwing around many ideas: Virtual robot eyes and ears, crowd-sourcing, artificial intelligence, research... Which one of those is your question? \$\endgroup\$
    – Anko
    Feb 25, 2013 at 20:35
  • 2
    \$\begingroup\$ What do you mean exactly by a "camera stream from Unity"? Do you mean to get video recording and project it into a 3D environment inside Unity? Do you mean to have two video input streams on different textures inside Unity? Do you mean using Unity to generate a video stream? \$\endgroup\$
    – Tetrad
    Feb 25, 2013 at 23:28
  • \$\begingroup\$ Also, check the faq: "Your questions should be reasonably scoped. If you can imagine an entire book that answers your question, you’re asking too much." \$\endgroup\$ Feb 26, 2013 at 13:14
  • 2
    \$\begingroup\$ Question is very vague. What exactly are you trying to achieve? \$\endgroup\$ Mar 4, 2013 at 9:17

1 Answer 1


If you want to allow the players to get some kind of flyCam CounterStrike-like you should have it calculated and redered in client machine because it's cheaper for your bandwith.

But actually what you are trying to perform could be done through RenderTexture and Camera.targetTexture despite the fact that you will not be able to avoid rendering process from the host machine you will still be able to not show the result on screen and actually send it to other players through network.

EDIT : To be more clear other players could also control the cam or any cam you want but the issue would still be the bandwith and processing power of the host machine for each cam you should count that you render and send the package to other player client... If other players have their own version of the game in local then you dont have to render it on the host you can render it on the client which will be much more responsive for everybody. I hope this answered your question


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .