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
3
Question by bug5532 · Apr 23, 2015 at 01:25 AM · animatoroptimizationprofileroptimizedirty

What are "Dirty Scene Objects" in Animator.Update in the Profiler

In the profiler I am getting a large percentage for "Dirty Scene Objects" this falls under Animator.Update. What is this referring to?

alt text

screen-shot-2015-04-23-at-022214.png (28.4 kB)
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

4 Replies

· Add your reply
  • Sort: 
avatar image
0

Answer by snmt_singh · Apr 23, 2015 at 05:05 AM

Unity internally uses the dirty flag to find out when assets have changed and need to be saved to disk. You can read document here : http://docs.unity3d.com/ScriptReference/EditorUtility.SetDirty.html

Comment
Add comment · Show 2 · 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 bug5532 · Apr 23, 2015 at 05:10 AM 0
Share

So is this only being brought up as I'm profiling in the editor? I will do a build and see if I get the same results.

avatar image bug5532 · Apr 24, 2015 at 01:25 AM 2
Share

I still get these dirty scene objects in a build as well. So I'm not convinced it is the same thing as the editor setDirty you have referenced to. Any other ideas?

avatar image
0

Answer by Patrascu · May 17, 2018 at 01:39 PM

Maybe @RomainFailliot can shed some light on what DirtySceneObjects does? And how to best optimize it's usage?

Comment
Add comment · 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
0

Answer by Mecanim-Dev · May 17, 2018 at 03:13 PM

We need to change the profiler marker name, code was moved around but look like we forgot to update the profiler marker name, it should be Animator.WriteProperties.

This code is executed from main thread and it does write all component properties: float, int, bool, and object reference like sprite. It does also send a transform change callback to update the whole transform hierarchy.

So either you have a lot of properties to write or your transform hierarchy is really big. One error that we saw a lot is some users have the bad habit to regroup ennemies under a single root transform, this is really bad as it prevent us to write all transforms in parallel, but I don't think this is your case because the WriteJobs marker would be a hot spot too and I don't see it in your capture.

So my guess is that you are writing a lot of properties.

Comment
Add comment · Show 1 · 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 Patrascu · May 17, 2018 at 03:41 PM 0
Share

Hi,

I'm experiencing a strange behavior in the profiler with Animator.DirtySceneObjects.

In our game I have 1 scene loaded, and as I check the Profiler on the Timeline view I can see that Animator.DirtySceneObjects takes us ~12ms on the main thread.

What is strange is that after I additively load 2 extra scenes and profile again, the same function takes a lot less time, ~0.12ms. I can't find an explanation for this behavior. I've attached below a link to 2 screenshots of profiling the 2 scenarios for reference.

https://imgur.com/a/W29h1nm

Thanks

avatar image
0

Answer by Mecanim-Dev · May 17, 2018 at 05:07 PM

there is nothing that come to mind that could explain this behaviour.

If you are willing to log a bug report with your project exposing the issue we will investigate it.

Comment
Add comment · 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

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

24 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 avatar image avatar image avatar image avatar image avatar image

Related Questions

What is a dirty scene objects? 2 Answers

Animator.Update has high CPU usage 2 Answers

GPU (render time) increase if screen size increase 1 Answer

Very Bad Performance on Android 3 Answers

Optimizing script to improve lag 1 Answer


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