# About root uv of abc groom

**URL:** <https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618>\
**Category:** Rendering\
**Tags:** unreal-engine\
**Created:** [November 14, 2020, 11:33am UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618 "2020-11-14T11:33:50Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![r\_o](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@r\_o](https://forums.unrealengine.com/u/r_o)\
**Post date:** [November 14, 2020, 11:33am UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/1 "2020-11-14T11:33:50Z")

</div>

Hello  
This may not be the story to discuss here,  
but is there a way to use blender to set root uvs in the groom?  
Or is there such a function in UE4 alone?

I spent all day doing this, but nothing progressed.  
I found a tutorial like this,

[XGen Guidelines for Hair Creation | Unreal Engine Documentation](https://docs.unrealengine.com/en-US/Engine/HairRendering/XgenGuidelines/index.html)

but it looks like a technique that can only be used in MAYA.  
Can you share any trivial information to do the same thing in blender?  
thank you.

---

<div class="post-metadata">

**Author:** ![virtualHC](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/virtualhc/32/1194710_2.png) [@virtualHC](https://forums.unrealengine.com/u/virtualHC)\
**Post date:** [February 25, 2021, 2:38am UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/2 "2021-02-25T02:38:34Z")

</div>

I’m trying to find the same. The Maya script is assigning UV data to each strand based on a given geometry (calculated by proximity) and then including that data as a custom attribute named groom\_root\_uv in the Alembic file. This attribute then can be retrieved in the material in UE. Probably a script needs to be made in Blender to achieve the same.

---

<div class="post-metadata">

**Author:** ![ArielQuinteros](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ArielQuinteros](https://forums.unrealengine.com/u/ArielQuinteros)\
**Post date:** [April 16, 2021, 4:12am UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/3 "2021-04-16T04:12:37Z")

</div>

I’ve been trying to find something similar, but no luck. Commenting to bump the thread, and admiting that I don’t know enough to script it myself. I founded this thread [https://developer.blender.org/T83838](https://developer.blender.org/T83838)

---

<div class="post-metadata">

**Author:** ![MalikuMane](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@MalikuMane](https://forums.unrealengine.com/u/MalikuMane)\
**Post date:** [July 16, 2022, 6:57pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/4 "2022-07-16T18:57:52Z")

</div>

Right now this post addresses the situation quite well [Adding uv data to alembic on export - #2 by flowb - Other Development Topics - Blender Developer Talk](https://devtalk.blender.org/t/adding-uv-data-to-alembic-on-export/24463/2)

---

<div class="post-metadata">

**Author:** ![gallant\_pigeon](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@gallant\_pigeon](https://forums.unrealengine.com/u/gallant_pigeon)\
**Post date:** [November 16, 2022, 10:45am UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/5 "2022-11-16T10:45:51Z")

</div>

The issue is quite complex, and ultimately boils down to the blender alembic exporter needing to be more configurable to play nicely with other tools (see links above). This is because different tools use different custom geometry parameter names and formats.

Interestingly it looks like Alembic OCurves has native support for UV data - Blender does actually export this. Consequently it might be possible to uplift the UE5 groom importer with out-of-the-box root uv support from blender. I’ll have a look at this some time this week. See: [alembic/OCurves.h at master · alembic/alembic · GitHub](https://github.com/alembic/alembic/blob/master/lib/Alembic/AbcGeom/OCurves.h)

If you want a temporary workaround for a sane workflow I’ve patched support for UE5’s groom\_root\_uv param into a fork of blender: [GitHub - Callum17/blender at feature/alembic\_improvements\_for\_ue5\_groom](https://github.com/Callum17/blender/tree/feature/alembic_improvements_for_ue5_groom)

Not yet decided if I care enough to look at adding support for guide hairs. Having access to per hair UVs should be sufficient for most use cases.

You will have to build blender as per norm:  
[https://wiki.blender.org/wiki/Building\_Blender/Windows](https://wiki.blender.org/wiki/Building_Blender/Windows)

If people are interested, the full set of custom geometry parameters UE5 takes (but blender does not support) are listed bottom of page:

> **[Alembic for Grooms Specification](https://docs.unrealengine.com/5.1/en-US/using-alembic-for-grooms-in-unreal-engine/)**
>
> Describes guidelines for exporting Grooms as Alembic files for use with Unreal Engine.

---

<div class="post-metadata">

**Author:** ![Eventide\_Dreams](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Eventide\_Dreams](https://forums.unrealengine.com/u/Eventide_Dreams)\
**Post date:** [November 16, 2022, 7:12pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/6 "2022-11-16T19:12:21Z")

</div>

Don’t know if this helps… but after watching the tutorial on youtube about this ([UE4 - Hair Color with Blender - Unreal Engine Groom Color 4.26 - YouTube](https://www.youtube.com/watch?v=7QuBs0MpIwM)), I asked this exact thing and the creator (Marvel Master, amazing ue5 tuts btw) said that recently, an addon to blender was created to export root uvs and groups in gumroad.  
Hope this helps, cause if anyone manages to find this add-on, please link it!! I cannot find it anywhere ☹

---

<div class="post-metadata">

**Author:** ![gallant\_pigeon](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@gallant\_pigeon](https://forums.unrealengine.com/u/gallant_pigeon)\
**Post date:** [November 17, 2022, 12:21am UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/7 "2022-11-17T00:21:15Z")

</div>

Quick search turned this up:

> [@Groom Exporter from blender, Free Addon](https://forums.unrealengine.com/t/groom-exporter-from-blender-free-addon/686778):
>
> I released a Free Blender Addon for exporting the new Curves object datatype from blender to an alembic file with the Groom schema dictated by Unreal Engine, the exporter gets the Attributes from the object to export it as properties on the alembic file. Download and more Information: [Gumroad](https://turbocheke.gumroad.com/l/Groomexporter) Quick Manual: [Drive](https://drive.google.com/file/d/16y_P9WNokVaycbTQyHd3HJo2cbrqXomD/view?usp=share_link) Currently, the addon was only tested on Windows. (Linux needs to research for the pyalembic library.)

---

<div class="post-metadata">

**Author:** ![turbocheke](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/turbocheke/32/1186254_2.png) [@turbocheke](https://forums.unrealengine.com/u/turbocheke)\
**Post date:** [November 17, 2022, 2:50pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/8 "2022-11-17T14:50:37Z")

</div>

I made the blender addon; I expect it’s useful for you, I will maintain the addon until Blender has native alembic attribute export. Some patches are on revision.

---

<div class="post-metadata">

**Author:** ![gallant\_pigeon](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@gallant\_pigeon](https://forums.unrealengine.com/u/gallant_pigeon)\
**Post date:** [November 18, 2022, 3:54pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/9 "2022-11-18T15:54:31Z")

</div>

I was having a play with your plugin yesterday - really appreciate the effort you’ve put into it (and it has prompted me to properly learn blender’s new curve entity / geometry node system - something I have been putting off 😃). It makes exporting the hair attribute data to UE5 extremely easy.

However I was running into an issue where the groom origin was incorrect once exported to UE5, and hence would fail to bind to the skeletal mesh asset. Looks like the blender surface mesh’s origin is not being taken into account by the plugin?

The state of interoperability between blender’s existing alembic exporter and unreal is not great: I’m not hopeful of seeing meaningful progress anytime soon given the amount of work that is needed to rewrite pretty much all of the C++ custom attribute logic, and add new UI features.

---

<div class="post-metadata">

**Author:** ![Eventide\_Dreams](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Eventide\_Dreams](https://forums.unrealengine.com/u/Eventide_Dreams)\
**Post date:** [November 18, 2022, 4:22pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/10 "2022-11-18T16:22:56Z")

</div>

I got it! Rly helpful. Thnk u very much!  
Is there anyway to export color maps with the add-on as well? I’m having a bit of trouble getting my Substance maps to match inside UE5, since I painted fur rather than hair, and the color need to match the UV coordinates. Is there a way the add-on can help with that?

---

<div class="post-metadata">

**Author:** ![Eventide\_Dreams](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Eventide\_Dreams](https://forums.unrealengine.com/u/Eventide_Dreams)\
**Post date:** [November 18, 2022, 4:37pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/11 "2022-11-18T16:37:46Z")

</div>

A little ashamed to admit I have no idea how to work the fork blender file you posted. Guess I’m just too n00b still for it.  
Did you ever found a solution for the alembic root problem?

---

<div class="post-metadata">

**Author:** ![turbocheke](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/turbocheke/32/1186254_2.png) [@turbocheke](https://forums.unrealengine.com/u/turbocheke)\
**Post date:** [November 18, 2022, 5:37pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/12 "2022-11-18T17:37:11Z")

</div>

Sorry to hear you have an issue.  
I want more information about the issue, to replicate on my side if possible and correct.  
The curve has an origin but I take the origin of the surface and apply a difference to the locations.  
 ![surface_origin](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/e/4/5e47e995c5ebef79b6aca0da7c90f411c0778292.png)

---

<div class="post-metadata">

**Author:** ![turbocheke](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/turbocheke/32/1186254_2.png) [@turbocheke](https://forums.unrealengine.com/u/turbocheke)\
**Post date:** [November 18, 2022, 5:47pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/13 "2022-11-18T17:47:28Z")

</div>

The addon only exports geometry and attributes assigned to the data, you can have a color per vertex on the hair, and unreal can use it.  
(On geometry nodes you can apply data from a texture on the geometry.)

Maybe I am confused but I understand you want to use a texture color on the length of the hair.  
(This case is completely unique to the artist, doable but you need to understand the hair Material Attributes.)

If it’s a color from the UV, the addon doesn’t have any problem if the hair has been assigned to that specific surface UV.

---

<div class="post-metadata">

**Author:** ![CoolSmek](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/coolsmek/32/595647_2.png) [@CoolSmek](https://forums.unrealengine.com/u/CoolSmek)\
**Post date:** [November 18, 2022, 10:31pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/14 "2022-11-18T22:31:41Z")

</div>

Having the same problem while trying to use the ‘Root UV’ input on a hair attributes node on the hair material in unreal. I’m honestly not sure if this is the correct setup, but I imagine it is. The idea is to drive the hair color from sampling the texture at the hair Root UV location.

 ![hairAttributes_rootUV](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/5/a/55a251fc1b5a81c7783710c2314bdfddb0ea623c.png)

In Blender a similar setup looks fine:

 ![blenderHairSetup](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/a/4/ca4448e271bc4858f70399db33a2f9f2e08a5aa1.jpeg)

When I import the alembic file into unreal it does say that the file ‘Has Root UV’  
But with the material setup from the first image, the hair color does not render as expected.

 ![unrealGroomImport](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/e/8/2e8db09a98b9f75db061d2c580fb5baa3337a4e4.png)

---

<div class="post-metadata">

**Author:** ![gallant\_pigeon](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@gallant\_pigeon](https://forums.unrealengine.com/u/gallant_pigeon)\
**Post date:** [November 18, 2022, 11:41pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/15 "2022-11-18T23:41:06Z")

</div>

Got to the bottom of the origin problem.

It’s a result of a difference between origins in the FBX exporter, and your groom exporter. The FBX exporter uses the world co-ordinates, but the groom-exporter uses co-ordinates relative to the origin of your armature (i.e. your root bone).

If you setup your root bone correctly (i.e. starting on the world origin), this shouldn’t be an issue.

@CoolSmek I also managed to reproduce this issue with the groom\_root\_uvs. The surface\_coordinate\_data looked fine in blender, and UE5 seemed to find them on import. But the UV data itself is either corrupted or zeroed within UE5.

![import_attr](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/c/3/cc3fb412d7e319bd0125c167e59e78e06855131c.png)

 ![col_from_groom_root_uv_mat](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/3/4/83481c2c202db57a16552fc39b87ed6aaffa57be.png)

 ![col_from_groom_root_uv](https://d3kjluh73b9h9o.cloudfront.net/original/4X/f/4/f/f4fe6084002c69a0d13b1277db197c63ef1d4cbe.jpeg)

UVs don’t looked right if viewed directly in the UE5 groom editor.

 ![root_uvs_view - Copy](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/1/7/6174678a5ff328f6412f4d74c580c0f7e12b0d36.jpeg)

The color attribute seems to come through fine though.  
e.g.  
This is where I baked the color attribute in blender (via geometry nodes) to achieve the same effect.

 ![geom_node_color](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/3/a/03acc41f6b12ba19abb48bd2ce02a589129166a5.png)

 ![col_from_color - Copy](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/0/8/c08423d22c2472469ce88ec348659dd9e4c39a15.jpeg)

For reference - this was in UE 5.1.0  
As a sanity check I loaded the groom mesh into 4.27.2 - same issue with the root UVs.

---

<div class="post-metadata">

**Author:** ![turbocheke](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/turbocheke/32/1186254_2.png) [@turbocheke](https://forums.unrealengine.com/u/turbocheke)\
**Post date:** [November 19, 2022, 6:57pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/16 "2022-11-19T18:57:59Z")

</div>

I found and fixed the issue, ironically my version of unreal 5.1 was refusing to render all the groom assets.

Was the name of a single variable, it’s solved now.  
Probably was made on the last minor version, because was working before that.

Later I see a problem I don’t remember exactly but Unreal and Blender have different UVs coordinates and made a custom parameter to activate an auto-correction on the coordinates on the export.

The fix will be on Gumroad today.

Pd: Thank you for the clear data captures, made my work easier.

---

<div class="post-metadata">

**Author:** ![turbocheke](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/turbocheke/32/1186254_2.png) [@turbocheke](https://forums.unrealengine.com/u/turbocheke)\
**Post date:** [November 19, 2022, 9:45pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/17 "2022-11-19T21:45:37Z")

</div>

Clarification on the UV coordinates.  
It’s the expected behavior of Blender,

 ![uv_blender.PNG](https://d3kjluh73b9h9o.cloudfront.net/original/4X/1/7/a/17a32622c15200bc7674c3fc8aa66d1c5c56f7d7.jpeg)  
Here I exported the ue4 logo from unreal to Blender, the object UV coordinates are “rotated”.  
 ![uv_blender_export](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/9/e/69ea80e9fcf5a4e2c1998225642a497051a4f955.png)  
The settings selected to export.  
 ![uv_unreal.PNG](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/a/5/0a53b66e965fbd1c51bc9497c5dab6f8c761f35d.jpeg)  
The imported Groom Asset on Unreal has the same UV direction.  
[My initial assumption was to solve the rotation, but the groom asset needs to have the exact UV of the mesh to apply a correct bind, for that doesn’t need a “correction”]

---

<div class="post-metadata">

**Author:** ![CoolSmek](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/coolsmek/32/595647_2.png) [@CoolSmek](https://forums.unrealengine.com/u/CoolSmek)\
**Post date:** [November 19, 2022, 11:29pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/18 "2022-11-19T23:29:59Z")

</div>

Thank you for the update! That has solved the root uv issue, I can now swap base color textures on instanced materials to get different hair color patterns! Very awesome!!

 ![hair_rootUV_screenshot](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/0/8/5087b0beff9611ca0e1547617cf6b5d1b24a5b99.jpeg)

---

<div class="post-metadata">

**Author:** ![gallant\_pigeon](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@gallant\_pigeon](https://forums.unrealengine.com/u/gallant_pigeon)\
**Post date:** [November 20, 2022, 1:25pm UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/19 "2022-11-20T13:25:44Z")

</div>

@turbocheke 0.13 fixed root\_uv issues for me too.

---

<div class="post-metadata">

**Author:** ![Daluz](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/daluz/32/608973_2.png) [@Daluz](https://forums.unrealengine.com/u/Daluz)\
**Post date:** [November 24, 2022, 9:30am UTC](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618/20 "2022-11-24T09:30:28Z")

</div>

Have no idea how you guys are getting to this. Does any good soul could record a step by step how to do this?

[Next page](https://forums.unrealengine.com/t/about-root-uv-of-abc-groom/153618.md?page=2)
