HScript vs Python in Houdini

   4721   2   1
User Avatar
Member
194 posts
Joined:
オフライン
My understanding is that Python can do almost everything that HScript can.
What can't be done using Python?
And vice versa - are there things that Python can do, but HScript can't?
User Avatar
Member
7046 posts
Joined: 7月 2005
オフライン
Actually, Python is missing a lot of functions right now, but it grows every release.

However, you can call Hscript from Python so the gaps can generally be filled in by Hscript.

You can't use Hscript to (easily) create or modify geometry in a SOP, which you can do in Python.

Hscript is _much_ faster than Python for custom expressions, so if speed is an issue (i.e. the expression will be executed many times) stick with Hscript.

Python is much better to script with for “scripts” that have loops, if statements etc.

Hope that helps

Cheers,

Peter B
Cheers,

Peter Bowmar
____________
Houdini 20.5.262 Win 10 Py 3.11
User Avatar
Member
194 posts
Joined:
オフライン
Thanks, Peter.
  • Quick Links