sideeffects / HoudiniEngineForUnreal-v2

Houdini Engine Plugin for Unreal Engine 4 - Version 2
http://www.sidefx.com/unreal
Other
295 stars 75 forks source link

Created Assets not Showing up in the World Outliner #49

Open ykhedar opened 3 years ago

ykhedar commented 3 years ago

I tried the latest HoudiniEngineForUnreal plugin with a small HDA created with the SideFX OSM Tools. The world is successfully created in the unreal engine. I have one problem though. How can I change settings for individual mesh actors generated by Houdini HDA in Unreal Engine. I can see only settings related to the HDA Actor and it seems all other actors are part of one big Mesh created by the HDA and hence I am not able to change the settings individually.

Thanks in advance for your help.

ykhedar commented 3 years ago

Upon further digging into the source of the plugin, i found that the following function/option give the functionality i am seeking.

Bake Option

Am I right about this and if yes does the sidefx team has it already planned to release this in a future release. Also if some pointers to add this myself would be really appreciated. Thanks again.

ykhedar commented 3 years ago

I have tried the following options until now:

  1. unreal_split_instances: Added this as a detail attribute. This creates Split Instancers but when I bake to actors, I see only these instancers in the world outline. I was able to see the individual static mesh actor in the detail view of the HDA asset.
  2. unreal_split_attr: Tried adding this both as detail attribute and also as point attribute and then specified a new attribute "unreal_id" to create a unique id for the points. I hoped that if all houdini objects have unique id, a mesh instansiater will not be created and instead i will get only the static mesh actor directly. But this did not happen. In fact I did not see any change w.r.t the option 1.

I tried this option because in the Wiki it was mentioned that:

Instancers Components are only created if the number of instances exceeds one. If an instance only has one instance, a StaticMeshComponent is created instead. This is especially useful if using packed primitives to split geometry.

and

Attribute and packed primitives instancers can now be split using attribute values. The name of the attribute used to split the instancers can be set via the "unreal_split_attr" attribute (string). The specified attributes values will then be used to create multiple instancers instead of one. ie: setting the "unreal_split_attr value" to "tile" will create a separate instancer for each value of the "tile" attribute.

So i thought if I do this then i will have unique instances and no instancer would be created. Clearly I am doing some mistake but not able to figure it out.

So still waiting for a working solution.

dpernuit commented 3 years ago

Hi,

It all depends on how your HDA is setup.

If when processing the OSM data, the building geometry you generate are just merged together in the HDA output, then the result will be one mesh with everything, as that is what merging geos is for.

If you want to separate the buildings, then I'd recommend packing them separately into individual packed primitives. This will create "one instance instancers", that the plugin will interpret as separate Static Mesh Components.

Baking the HDA will then result in individual Static Mesh Actors.

The unreal_split_instances and unreal_split_attr attributes are used when you're actually instancing meshes in your HDA, ie: instancing building meshes (from Unreal) via the HDA.

ykhedar commented 3 years ago

Hi @dpernuit , Thanks for your tip. I was able to get this to work by using the Pack node before merge node. The names of all these meshes so generated is generic in nature. It is of the form "$hda_asset_name_instancer0*". I tried adding the "unreal_generated_mesh_name" and "unreal_bake_name" to override this generic name. But it seems to have no effect. Could you please point me to the solution. Thanks again. :)

ykhedar commented 3 years ago

I also tried using the "unreal_output_name" and it changes the name of the meshes in the Houdini Outputs dialog but not in the World Outliner.

faxcorp commented 1 year ago

@ykhedar Hello, have you ever solved this?

mchataway commented 10 months ago

Hi there, I am experiencing the same issue, in that the "unreal_output_name" and "unreal_bake_folder" attributes don't seem to be being respected at all. I've tried every combination of setting those attributes on the prims and at the detail level. Baked meshes always go into HoudiniEngine/Bake folder, and are always named something generic after the name of the HDA type.

If anyone has some insight into this or know how's to solve it, I'm all ears!

faxcorp commented 10 months ago

For me, the issue was solved with an update of a plugin. Anyways, try my HDA, for me it works 100% of the time now. Its gonna add attributes for UE https://github.com/faxcorp/FreeHDAs/blob/main/sop_F4X203.dev.Unreal_name_connected_pieces_set_attributes.1.0.hdalc

mchataway commented 10 months ago

Thanks @faxcorp , I've got it working now after looking closely at your HDA! I think the problem I was having, is that I was setting some unreal* attrs at the detail level, and some at the prim level. By just making all of my unreal* attrs at the prim level it seems to be working now :) Thanks!

faxcorp commented 10 months ago

Hey, thats great to hear! I've been struggling with this type of thing too. By the way, sidefx doesn't check this github, you gotta go to their forums for support... On Wednesday, 26 July, 2023 at 02:37:00 am GMT+3, Mark Chataway @.***> wrote:

Thanks @faxcorp , I've got it working now after looking closely at your HDA! I think the problem I was having, is that I was setting some unreal* attrs at the detail level, and some at the prim level. By just making all of my unreal* attrs at the prim level it seems to be working now :) Thanks!

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were mentioned.Message ID: @.***>