Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
1
Question by sotha_sil · Jan 06, 2014 at 07:27 AM · cameraperfomance

Many camera objects or Set Position of one camera perfomance

Hello, I have a game where different rooms will require camera to be at different angles, fov, position, script etc.

Now I was thinking about best way to approach this, Easier option seems to be to just place many camera objects, one for each room and then only have one camera enabled at a time via script.

another more complicated option I thought of is to have one camera and reposition/re-set settings of it for each room. I could have dummy CameraTarget objects, and I could store required info in them, then move/set main camera to CameraTarget position and settings.

from difficulty/developer friendliness point of view, first is better for my game. Script is easier to write, and I can preview what is seen through each camera easily. But will there be any performance downside for this?

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
2
Best Answer

Answer by ncallaway · Jan 06, 2014 at 08:31 AM

Having several Cameras in a scene won't hurt performance as long as you only have one Camera enabled at a time.

Keep in mind that creating a Camera with the menu "GameObject" > "Create Other" > "Camera" will create a GameObject with several components attached. One of those components will be an Audio Listener. Really, you should only have a single Audio Listener in the scene (it doesn't have to be a Camera). So, if you go with the "many Cameras" approach, you might want to detach the Audio Listener from the Camera. You'll need to come up with a system for moving an object that contains an Audio Listener to the position of the currently active Camera.

Comment
Add comment · Show 3 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image sotha_sil · Jan 06, 2014 at 09:07 AM 0
Share

Thanks, Would Enabling/Disabling of audio listener as well as camera work or does it have to persistently be one one active gameobject?

avatar image ncallaway · Jan 06, 2014 at 09:11 AM 0
Share

Honestly, I haven't tested this out myself. Based on this answer: http://answers.unity3d.com/questions/267213/there-are-2-audio-listeners-in-the-scene-please-en.html it sounds like you can have many, as long as only one is active at a given time.

avatar image sotha_sil · Jan 06, 2014 at 09:19 AM 0
Share

cool, thanks again

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

19 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

How to make camera position relative to a specific target. 1 Answer

Rotation seems to pass through condition checks 1 Answer

[Solved]How to change camera perspective ? 1 Answer

Camera only renders to textures once modified during Play (from Inspector) 1 Answer

How do you position an object relative to the camera? 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges