Decal Become square when spawning

So when I make a decal actor, It’s circular however when i spawn it though the blueprint it becomes square? Does anyone know a way to fix this?

Hi Imploding Dragons -

Can you post a screenshot of your setup so we can begin to help you debug this problem? In particular what is the decal material setup and how is it spawned in the blueprint.

Thank You

Eric Ketchum

Ok Updated the question with picsalt text

Hi Imploding Dragons -

Thank you for the pictures, I was able to reproduce this issue and it is a bug, specifically with the Spawn Decal node in blueprint. I have put in a bug ticket with our engineers and will keep you informed as we work to correct this issue.

Again thank you for your help in tracking this down -

Eric Ketchum

Does this mean that it would work properly in c++?

Hi Imploding Dragons -

I have not explicitly tested this in C++ but the error is not in the deliver of the spawn location to the decal (which would be the C++ functionality) but in how the decal is rendered at that location which would not change between the two methods.

We are addressing this issue and I will let you know as soon as I have a confirmed and tested fix.

Thank You

Eric Ketchum

I can reproduce this bug as well. I’m not dynamically spawning decals in a blueprint; rather, I just have a decal actor in the components graph of my blueprint, and it’s quite square compared to what it should be.

Decal in blueprint:


Decal in world, non-blueprint:

Decal material:

Hey -

Can you let me know what version of the engine you are using?

Thank You

Eric Ketchum

I’m having the exact inverse problem in Unreal 4.8.2.

When I create a “Decal Actor” and place on a scene, the decal gets squared. But, if I spawn the decal in a blueprint on “begin play”, then it shows the circle as expected.

Below is a picture of the “Decal Actor” with its squared material:


Below is a picture of the material used:


And on the left of the picture below is my decal I spawned on “begin play” of the level.


Let me know if more information is needed. Thank you.

Hi AranHase -

It has to do with the rotation of the Decal at Spawn or at Placement. Typically the engine does not dictate the orientation of the decal and it must be set by the placer of the decal. I would need to see the BP placement information from the spawed decal versus the placed decal, which looks like in your pictures is actually inside of a BP. If that’s the case then your have local rotation of the decal and rotation of the BP actor as a whole that must be aligned.

Thank You -

Eric Ketchum

Thank you a lot for the answer. That was it, and now my mistake is very obvious and makes a lot of sense. The decal actor works perfectly if I rotate it the same way I rotate the decal spawned in blueprint.

#Thank You Eric!

Thank you for this answer Eric, and thanks for the question AranHase!

For anyone who is unclear on the solution, try using a value of -90 for the y of the rotation of your decal actor (pitch value).

The actor currently defaults to 0 rotation which is parallel to the ground, so it just sort of smears, not showing the decal which is decided to point down toward target surface.

#Engine Solution

Potential engine solution would to have decal actors default to pitch -90 or 90

There is code for this in 4.8.2 source, DecalActor.cpp, but its not working, I think because the relative transform is assigned before Decal become root component and also root components dont have relative transform (everything else is relative to root component)

Decal->RelativeRotation = FRotator(-90, 0, 0);

RootComponent = Decal;

EDIT: yup that was the problem, I’ve implemented a solution

#Solution Implemented, Pull Request Made

You can support my pull request to fix this Decal bug here:
https://github.com/EpicGames/UnrealEngine/pull/1416

(must be logged into github to access above link)

#Pic Of My Github Engine Build Solution

Here’s a pic of my custom UE4 engine build where the issue has been corrected:

Notice how default pitch is -90 again in my custom engine build! Pull request submitted!

Have fun today!

:slight_smile:

Rama

1 Like

Nice catch Rama! This will make easier for people new to UE4 like myself.

Thank you for all your contributions to the community, specially your wikis, they were extremely useful to me!

I believe that this has been corrected already in 4.9.

Eric Ketchum