Video summary
In this tutorial, Andy Pixel demonstrates how to build a custom Houdini Digital Asset (HDA) within Unreal Engine 5 that automatically generates and orients trigger volumes around selected objects. The process begins by creating a new geometry node in the Houdini engine environment where inputs are managed separately from outputs using subnets. By defining specific parameters, such as promoting an object input to accept world outliner selections directly via naming conventions like "outliner," the asset is configured to listen for user interactions within Unreal Engine 5 without requiring manual setup every time it is instantiated in a level.
Once inside the Houdini node network, the workflow focuses on converting imported mesh data into usable volume shapes that adapt dynamically to their contents. The creator utilizes an object merge node to consolidate multiple selected assets and applies a bound node set to "oriented bounding box" mode, ensuring the resulting shape fits tightly around the geometry rather than defaulting to a simple cube. To handle non-uniform scaling effectively, particularly for irregular objects like shipping containers with dense Nanite topology, an extract transform node is employed to isolate translation, rotation, and individual scale values along each axis before passing them forward in the network.
The final step involves generating the actual volume actor instance using a wrangle node that assigns specific Unreal Engine attributes based on the calculated dimensions. By writing code such as `v@scale *= 0.5`, the creator adjusts the size of the generated box to better fit around complex assets, and then populates an attribute with the class name "trigger_volume" so that Houdini knows which actor type to instantiate in Unreal Engine 5. After saving these nodes back into a project folder and rebuilding instances within the content browser, users can simply select multiple objects in their level, activate the asset's selection mode, and click use current selection to instantly see perfectly oriented volumes wrapping around their chosen items.
Read the full video transcript
howdy guys
andy pixel here and in this video i'm
going to talk about how to create an hda
for the houdini engine 4 unreal 5 here
that will
automatically place a volume actor
around a selected set of
objects and it'll orient it correctly so
let me demonstrate how this will
work and the hd that we're going to
create
in this video so i just instanced the
hda into the level
and let's go take a look at the details
panel over here and we're going to go
over into this particular area here and
i'm going to go and say
start selection and this will allow me
to select a certain amount of
actors here then i can say use cur
selection
and you'll notice that it produces a
trigger volume here
so if i were to select this guy and go
into brush editing mode you can see we
have this
trigger volume that's been oriented
correctly around those selections
we can update the selection to whatever
actors we want so if i say start
selection
let's add a couple more of these guys to
use current selection you can see now
that the
volume itself has updated and reoriented
to the new selection so let's take a
look at how we build this
inside of houdini with houdini engine
first thing to do is go and create a
geometry node so let's drop down the
geometry node
i'm going to call this get objects and
then i'm going to select it do a shift c
that'll create a subnet around it
because i want to control um
my inputs and my outputs separately so
i'm going to call this
ip add volumes to selected
like so i'm going to right click on this
guy say create digital asset
and i'm going to put in my namespace
and my version number like so
and then just clean up the label
and then we need to save it to an actual
location so i'm going to put this
into my current unreal project here so
we're going to go to unreal projects
we're going to go to volume actors
content hda we're going to save it right
in my hda folder so
hit accept that'll bring up the type
properties i'm just going to put a 1.0
for the version number and then go and
hide on my default
ui that comes with the hda so with that
hit accept
and dive into my hda and then set up an
object merge
node here we'll call this get objects as
well
and i want to actually import the
transform information from all the
assigned objects that we assigned to
this particular hda
so then i'm going to drop down a null
node and this will just serve as an easy
way to
get the output from this object merge
node so we'll say out objects
like so all right with that done we need
to go to the type properties and we need
to promote this object one parameter so
to do that i tend to use the alt middle
mouse click
and then i want to give this a proper
name and a proper label
and now inside of the houdini engine for
unreal if you were to put outliner
in front of the name of this particular
parameter
it will automatically default the object
input to the outliner selection type
so just keep that in mind so i'm going
to call this outliner objects
and then outliner objects
like so there we go hit apply
and accept that's pretty much all we
need to do right now so i'm going to hit
save node
i'm going to go to my unreal project
here and
let's go i'm going to show explorer here
we're going to go and find that hda that
i just made so
ipad volumes is selected i'm going to
drag and drop that into my content
browser here
and hit save and then i'm going to right
click on it and say
instantiate at the origin like so
there we go also make sure that your
houdini engine is started and stuff like
that it will auto start if you
if it's not already started when you
instantiate the hda
all right so what we can do now is go
and assign let me actually get rid of
the previous example here so we can do
is we can go and assign
objects to this input so you notice that
it's actually automatically
converted over to the world outliner
input there's a lot of different types
of
inputs here so by putting that outliner
in front of the parameter name
it defaults to that which is great so
i'm going to hit the start selection
you'll notice that the button switches
over to use current selection which
means that it's
waiting for a selection so i'm going to
select a bunch of objects
and then come back to the details panel
and hit the use current selection button
and what happens is they get assigned
into that stop input here so now i have
both those containers in here
the cool thing about this is i can do a
control alt and
o and this will automatically open up my
unreal scene but inside of houdini so i
can continue to work on my hda
all right so once you're inside of
houdini here i'm going to go to my
desktop
i usually hit l to space out all my
nodes all right and then i go and find
the hdr that's currently active in my
unreal scene
i turn everything off so just by
selecting it and hitting the blue flag
and then i come in here allowed in
editing of contents
and if i were to hit f with my cursor
over the scene view here you can see i
have the imported
objects and you'll notice that if i go
to wireframe by hitting w on the
keyboard
i'm getting a really interesting
topology that is not the topology of the
actual asset these are dense polys but i
have nana turned on and so this is the
result that
unreal is sent over to houdini for the
houdini engine to process
this will work just fine for this
particular hda so
i'm going to drop down a geometry node
here and we're going to call this
add volumes
like so i'm going to turn off this
display flag on the get objects there
because we don't need to
output that particular mesh i really
just want to convert this into a volume
so
i'm going to do an object merge node i'm
going to call this get
objects i'm going to turn off the
transform because we've already imported
the transform information
and i want to get the objects from that
get objects geometry node
like so so now it's imported into this
geometry node so it grabbed it from here
and just imported it into here
cool so with that done all i need to do
is put a bound node around this
let's do that it's real easy but the
more important thing that we want to do
is we want to constantly orient this
to the object's shape
so we need to turn on this oriented
bounding box and you'll see that it
orients it correctly
pretty cool now how do we get this over
into unreal how do we get this
particular shape because currently we
have no
way of converting this over to like an
instance
of an actor and so to do that we use the
extract
transform node and we need to drop down
a box so if i drop down a box and we
just keep it at a size of one and one
and one what will happen
is this box will then get transformed
translated rotated and scaled
or transformed over to this particular
box all right so i'm going to
pump this guy into the first input the
bounds into the second input and you'll
notice that all i'm left with is a point
but this point is very important here
because we can instance
a particular actor onto this the other
cool thing about this is it comes with
the orient attribute
gives us a pivot and you can go into the
extract transform node and change this
over to
a translation rotation and non-uniform
scale which is really
useful for volumes because they aren't
always just a perfect cube
so now you get the scale values so in
order for this to work for this actually
produce a volume inside of the
houdini engine for unreal all we need to
do is drop down a wrangle node we'll
call this unreal adders
for attributes and we need to assign the
s at unreal instance attribute
with some volume so inside of
unreal over here if you go to the create
tab go to volumes these are all the
volumes that you can
create and so i'm going to create a
trigger volume and all you need to do is
just
copy the name and then paste it into
that unreal instance
attribute in houdini with no spaces so
let's do that
now all right so let's go and turn this
guy on
i'm going to type in trigger volume
semicolon do a control enter to commit
the code
and then i found also that we need to
basically cut our scale in half so i
just do
v at scale times equals 0.5
like so there we go i'm going to right
click on my hda say save node
i'm going to go back into unreal and i'm
going to hit
rebuild all instances
on my hda in the content browser and
with that you now have a volume
how cool is that
very very cool all right and so that's
basically what i wanted to show this
scene is all set up with
nana and stuff like that and it is cool
to turn this on because it is a cool
view
but you can see that nanite is working
each one of these shipping containers is
around 200
000 polys so nanite is a beast
all right so hopefully you guys found
that uh useful
let me turn off the display here but
that is how you create oriented
volumes with the houdini engine for
unreal five thanks so much
you