alexxbb / hapi-rs

Idiomatic Rust bindings to Houdini Engine C API
MIT License
65 stars 7 forks source link

Any plans to integrate this with Bevy? #18

Open thedodd opened 1 year ago

thedodd commented 1 year ago

Having a streamlined Houdini -> Bevy content creation workflow could be a bit of a game changer for building games/apps with Bevy.

mike-mortimer commented 1 year ago

Agreed, this kind of DCC pipeline would help Bevy adoption too.

alexxbb commented 1 year ago

Yes, it would be great to integrate it with Bevy. As a matter of fact I tried this about a year ago, but I didn't have much experience with Bevy at that time. ( And still don't have it 😆)

The biggest downside is licensing. You need a commercial Houdini license for third-party implementations like this one which can put off potential users.

Having said that, I would like to learn Bevy better and try again this Fall.

thedodd commented 1 year ago

I'm going to be experimenting with this a bit for some stuff I am building. I'll keep it modular so that if I make progress on this, I'll be able to push the code to crates.io (or PR here) and such. Likely I'll use Bevy UI (for any UI stuff, params and such) to try to make it future proof.

My primary objective will be to use a Houdini .hda as a core part of a Bevy scene. That way I can do as much of the asset creation pipeline in Houdini, and then just load it as a Bevy scene.

One thing which I think will be quite important, and also quite doable, is to be able to export various attributes from Houdini, and have those attributes treated as Bevy components. This will be a nice way to integrate the asset creation pipeline with an abstract representation of logic. Then on the Bevy side, we just parse those attributes and attach them as components to the spawned entities using Bevy's reflection system (already a tried and true pattern, just not in the context of Houdini).

That would be killer. Once the Bevy editor ships, Bevy will be much closer to being a viable alternative to Unity and such. Well, it already is, but this will alleviate much of the boilerplate.

alexxbb commented 1 year ago

Hey @thedodd sorry for the late reply.

I'm curious to see what this may turn into. It can be a great test for the library - some APIs are missing (less common) and some design decisions were made to make it simpler and user friendly at the cost of maybe some overhead. But I'm open to changing it if necessary.

I should also have more time to experiment with it later this year.

Good luck!

thedodd commented 1 year ago

Well, unfortunately I only learned after the fact that the Indie license only grants access to the Unity & Unreal engines. In order to use the engine API for this use case, I would need to drop a pretty solid amount of money ... in order for me to do a bunch of work hahaha.

So, at this point, it is a no-op for me.

alexxbb commented 1 year ago

Yes, exactly, this is very unfortunate, but makes sense from SideFx business point of view.

If Bevy (or Rust game dev in general) takes off and people start making money with it, then maybe it will be of SideFx interest to support another ecosystem.

Until then, this library is for niche use cases in VFX studios which have tons of Houdini licenses 🙂

NicTanghe commented 1 month ago

Well, unfortunately I only learned after the fact that the Indie license only grants access to the Unity & Unreal engines. In order to use the engine API for this use case, I would need to drop a pretty solid amount of money ... in order for me to do a bunch of work hahaha.

So, at this point, it is a no-op for me. @thedodd

I`m pretty sure what you are saying is untrue.

The indie license gives you access to houdini engine wich is what is used by the engines to process the hda`s. And is also what whould be used for using this with bevy.

Im pretty sure about this but do correct me if I`m wrong

alexxbb commented 1 month ago

I'm pretty sure you can't use an Indie license with custom plugins which this library qualifies as.

Check out this FAQ

I would happy to be wrong though.

The official Unreal and Maya plugins are distributed as binaries with inbuilt Indie license support.

NicTanghe commented 1 month ago

Ah yes on closer inspection i was wrong.

i wil send sidefx a mail asking if some sort of exception could be made to allow for integration with a publicly available opensource engine. I be-leave everyone can profit from some more rust in the vfx industry. and maybe we can get you a free non-free license.

luxalpa commented 3 weeks ago

I have been using this with an indie license just fine so far.

https://www.sidefx.com/buy/#houdini-indie it says to use Houdini Engine license right there. That's what I did and for the last 2 years or so I had no problems with that.

NicTanghe commented 3 weeks ago

The discussion was not on using this as a standalone project but to look at integrating it with bevy in the same way it is integrated in unreal or unity. and it seems that for that a higher tier license is definitely needed ?

luxalpa commented 3 weeks ago

I don't see why a higher tier license would be needed? I could perfectly integrate my Houdini Engine plugin with Bevy instead of using it in my custom game engine.

Or is this about using the plugin without needing any paid Houdini license?

doppioslash commented 3 weeks ago

There are 2 key distinctions here:

  1. Apprentice licenses vs Indie licenses vs Studio licenses
  2. Houdini Engine for Unity&Unreal only licenses vs generic Houdini Engine licenses that will allow it to work with custom engines

With just an Houdini Apprentice license afaik you can't use Houdini Engine at all.

If you qualify for Houdini Indie licenses, you can have up to 3 free generic Houdini Engine licenses, that will work with any app, including a custom engine like Bevy.

If you need a Studio license, you only get free Houdini Engine for Unreal&Unity licenses, but not the generic Houdini Engine licenses.

Since Bevy is open source, I'd imagine if you write to SideFX they could be willing to help sort this out.

alexxbb commented 3 weeks ago

@NicTanghe yes, for this kind of integration SideFx would need to issue a special license. The issue is that no one can guarantee that this license won't be used by someone for commercial purposes. With the official Unity/Unreal plugins the license is distributed in binaries. SideFx would have to distribute the Bevy plugin themselves in a binary form and Im sure they are not interested in this at all with the current state of GameDev in Rust/Bevy. There are dozens of much more widely used game engines around which SideFx doesn't care about - they don't make money.

NicTanghe commented 3 weeks ago

@alexxbb

Ok so what you`re saying is that if they issue a free license for usage to make a plugin for bevy.

they cant check if they would also make a plugin for developing a plugin for an in-house engine ?

I think they can check if someone doing business with said person suddenly has a Houdini plugin in their engine and they could require telemetry data to be on for usage. Although it would always be in good faith. and i be leave that sideFX has enough heart left for such a move.

But they might get a relations hit with unreal/unity of they do decide to do something like this.

PS. I think i might have never send a mail but I'm not sure and it will likely be a while before i try again..

PSS. more people making games with an engine that has Houdini support the more potential customers they have. Its a good way to take a part of blenders market. And if possible a godot engine should also be made.

luxalpa commented 5 days ago

If you qualify for Houdini Indie licenses, you can have up to 3 free generic Houdini Engine licenses, that will work with any app, including a custom engine like Bevy.

It seems that this got changed stealthily this week. My Houdini Engine integration into my game no longer works with the error "Houdini Engine Indie license found but it can only be used with approved Houdini Engine plugins.".

alexxbb commented 4 days ago

Oh wow, could be that SideFx inadvertently allowed Indie license in third-party plugins without even realizing it!?

luxalpa commented 4 days ago

Yes, I have contacted SideFX support with this regard and they said using Indie Engine license for anything other than the official plugins was never supported. I also submitted an RFE and gave a bunch of reasons for why Houdini engine is very useful for indie devs.

NicTanghe commented 3 days ago

Great i whould second that RFE if i could but you need a studio license for that aswell. I`m thinking it being usefull for indie devs is why it costs extra.