Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 14 Next capture
2021 2022 2023
2 captures
12 Jun 22 - 14 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 hawksandwichgames · May 29, 2018 at 06:34 AM · renderingcullingskinned mesh renderer

[Solution in answers] Skinned Mesh Renderer only appears if it's visible in the Scene window

So, I've got an animated knife as a child of the first person camera. When I click, the knife swings. Everything works great! Except when the scene view isn't pointed at my player...


If I play the game in a maximized game window, the knife doesn't render. If I don't play maximized, but don't have the scene window on screen, the knife doesn't render. If I walk out of view of the scene window, the knife doesn't render.


It's acting as if the scene view is my "camera," and when the skinned mesh renderer isn't displayed by that "camera" it doesn't render. You'd expect this behavior but with the actual camera instead of the scene view.


I've never run into a problem like this before, so I'm very very confused. I'm sure there's a setting or something that I'm overlooking. Any help is greatly appreciated :)

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
8
Best Answer

Answer by hawksandwichgames · May 29, 2018 at 06:55 AM

Alright everyone, I've found a solution. I don't know exactly what fixed it, but I've changed a bunch of settings on the knife and camera. For anyone with a similar problem, here are the settings I suspect have something to do with it.


  • The Animator component has Culling Mode set to Always Animate.

  • The Skinned Mesh Renderer has Update When Offscreen checked true.

  • The Skinned Mesh Renderer has Dynamic Occluded set to false.

  • The Camera has Occlusion Culling set to true.

  • The Camera has Allow Dynamic Resolution set to false.


I'll mark this answer as correct and leave the question here so it might help someone else.

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 SohailBukhari · May 29, 2018 at 07:21 AM 0
Share

All points are valid regarding Skinned $$anonymous$$esh Renderer.

The Animator component has Culling $$anonymous$$ode set to Always Animate.

The Skinned $$anonymous$$esh Renderer has Update When Offscreen checked true.

The Skinned $$anonymous$$esh Renderer has Dynamic Occluded set to false.

The Camera has Occlusion Culling set to true.

The Camera has Allow Dynamic Resolution set to false.

avatar image Oneiros90 · May 11 at 02:17 PM 0
Share

Always Animate on the Animator fixed for me

avatar image
0

Answer by PSDfriends · Sep 09, 2020 at 08:42 PM

Thanks hawksandwichgames your solution worked

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 miron83 · May 10, 2021 at 07:44 AM

@hawksandwichgames Actually only the The Skinned Mesh Renderer -> Update When Offscreen -> checked true does the trick. However, this isn't the ideal sollution because it lowers the performance as the mesh bounds are remapped all the time. It's ok if that happens for a single mesh but when you have them hundrets it can really impact the framerate.

Check: https://docs.unity3d.com/Manual/class-SkinnedMeshRenderer.html and https://docs.unity3d.com/Manual/class-SkinnedMeshRenderer.html#bounds

the mesh is remapped when Update When Offscreen is set to true, when you set it back to false the bounds get to the original possition.

in previous versions of Unity you could recalculate the bounds with this bit of code.

 modelObject.GetComponent<SkinnedMeshRenderer>().sharedMesh.RecalculateBounds();

And that would be great so that I could rempap the bounds when the animation happnes. However, it doesnt work anymore, or at least not for me...

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 miron83 · May 10, 2021 at 11:54 AM 0
Share

i found solution here: https://answers.unity.com/questions/1588910/get-exact-skinnedmeshrenderer-bounds.html

avatar image
0

Answer by x1alphaz1 · Nov 06, 2021 at 01:46 PM

For Anyone who's facing this issue. U need to set the rootbone position of the attached object to the position of the Main SkinnedMeshrenderer rootbone position

Example:

 O1 = Main.GetComponent<SkinnedMeshRenderer>();
 O2 = Attached.GetComponent<SkinnedMeshRenderer>();
 O2.rootBone.transform.position = O1.rootBone.transform.position;
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

94 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 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 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 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

My objects are rendered even though I can't see them on screen 0 Answers

Where To Learn Occlusion Culling Scripts 1 Answer

How to render objects outside the camera's view? 1 Answer

Changing Renderer in networked doesn't change rendering on other player screens 0 Answers

3D Objects are not being in their regular shape at distance 2 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