x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Are there any issues with setting a negative scale to a mesh?

Something like a scale of 1,-1,1. I have a skeletal mesh I'd like to mirror but I don't know if that's a game design "don't" or not. Thanks.

Product Version: UE 4.11
Tags:
more ▼

asked Jul 10 '17 at 09:59 PM in Rendering

avatar image

swiss_cheese9797
158 29 50 69

(comments are locked)
10|2000 characters needed characters left

3 answers: sort voted first

Yes, there is! If you try to use Hierarchical Instanced Static Mesh Component then it will show your mesh as inverted (you will see only inside part of the mesh, not outside). Weird thing...

more ▼

answered Nov 21 '17 at 03:25 PM

avatar image

raianlp
32 4 10

(comments are locked)
10|2000 characters needed characters left

Hey Guys,

Negative scaling on ISMs is not supported.

Reason being is that meshes with negative scales require a different cull mode which would require an additional draw call.

more ▼

answered May 30 '18 at 03:07 PM

avatar image

Alex O ♦♦ STAFF
2.2k 3 6 8

avatar image Bob3DGames Nov 01 '18 at 09:39 PM

Alex, please can I ask for a little more detail for my understanding?

I have a car door actor which contains a skeletal mesh, some collision meshes, an animation and some code. Inside the parent car actor I have two copies of this, one with a negative y-scale. I did this deliberately as I thought it would be cheaper than having two entirely separate skeletal meshes, each with their collisions and animations. Am I right or wrong?

The strange thing is that it all looks and works perfectly fine except the mirrored door's collision mesh is in the wrong place, and moves around strangely when the car moves.

Also, I'm still a bit of a noob - what do you mean by 'cull mode'?

avatar image Alex O ♦♦ STAFF Nov 02 '18 at 01:45 PM

Hey Bob,

This sounds like an issue I entered a while ago: https://issues.unrealengine.com/issue/UE-53895

It was marked wont fix because of expected upcoming changes to this system.

My understanding of culling is that certain polygons are not shown if they're not visible. I think culling is unrelated to the collision mesh.

avatar image Bob3DGames Nov 02 '18 at 05:57 PM

Thanks, that does sound like the issue I've been having. I'll try the workaround mentioned there. I recall experiencing a lot of crashes with the attach to component node though but I might just be remembering something similar but different.

Edit: The workaround works to a certain extent. The collision mesh moves correctly with the animation of the skeletal mesh, but there's no actual collision, even when set to 'block all'.

Edit 2: Never mind, I was being silly (it was a Friday afternoon after all) - I'd turned collision off for the skeletal mesh and on for the collision mesh, forgetting that since I was attaching the collision to the skeletal mesh I was effectively making it a child and so it was inheriting the no collision setting of the skeletal mesh. D'oh!

All is working well now!

(comments are locked)
10|2000 characters needed characters left

I had trouble mirroring attached components during development at some point:

  • Negative scale in socket on parent static mesh leads to some wierd glitches and not saved properly.

  • Apart from issues above, when they do work ,normals is fliped and it has to be 2sided material to fix this issue.

  • Also there should be problems with correct collision location.

The only way i found so far to achieve Mirrored effect was to do some work with relative location after attaching components in c++ ( My socket names contains some characters to indicate is socket needs to be mirrored):

 if (IsMirroring(SocketName))
  {

         auto NewTransform = AttachableModuleComponent->GetRelativeTransform(); 
         NewTransform.Mirror(EAxis::Y, EAxis::None); // Mirroring Y
         AttachableModuleComponent->SetRelativeTransform(NewTransform);
 }









more ▼

answered Nov 05 '18 at 03:40 PM

avatar image

Kiry
21 2 6

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question