LWPy - An Intro to Python for Lightwave

Very cool. I'm not a programmer, so it's pretty foreign to me, but I think this is a very good idea.

BTW -- I realize it's early in LW 11's life and it's integration with python, but why haven't we seen some cool python scripts hitting the public yet? Is it difficult to take scripts that were created for other programs (Maya, Blender, etc.) and convert them for use with LW? Forgive my ignorance.
 
Very cool. I'm not a programmer, so it's pretty foreign to me, but I think this is a very good idea.

BTW -- I realize it's early in LW 11's life and it's integration with python, but why haven't we seen some cool python scripts hitting the public yet? Is it difficult to take scripts that were created for other programs (Maya, Blender, etc.) and convert them for use with LW? Forgive my ignorance.

Hey thanks! Actually, I'm not a programmer either (yet).

There is functionality from the host applications that wouldn't carry over even if you did sucessfully convert the program from say Maya to Lightwave. I would say the main reason there hasn't been a lot of Python activity is we're still learning it. There are some folks here like Celshader who are well-versed in Python, but writing a plug-in that gets called within Lightwave is very different. It's like writing a C plug-in that doesn't get compiled.
 
Very cool. I'm not a programmer, so it's pretty foreign to me, but I think this is a very good idea.

BTW -- I realize it's early in LW 11's life and it's integration with python, but why haven't we seen some cool python scripts hitting the public yet? Is it difficult to take scripts that were created for other programs (Maya, Blender, etc.) and convert them for use with LW? Forgive my ignorance.

Actually, Jen Hachigan (spelling?) has put a few threads up posting scripts for functions she has found useful.

I think the situation is perhaps a bit of a cycle that needs to be broken. Most people in the LW community don't know Python. This makes it hard for them to get excited about it. Without excitement not many people are motivated to learn python (but rather stick to LScript)

It will take time and more people to learn Python and grow the userbase, and threads like this (and Jen's) will help.
 
I'd like to say that these are essential viewing for beginners - they really helped me start.

Thanks, that's good to know.

It's still a major WIP but I think now is a good point to release this. I've started a LWPy Wiki that hopefully we can all learn from. It's small but more stuff will be added.
 
+1 to this - I just upgraded to 11 and was all excited to jump in and start learning Python and programming cool stuff and got stopped cold. 11 is still shipping with the LW 10 docs, which make no mention of Python.

Having said that, I'm still excited and looking forward to not only learning but contributing back, hopefully. :)
 
LW11.5 ships with Python documentation in its "lwpython11.5.zip" in the "sdk" folder. 11.5 also offers a new option for simplified "single-shot formatting" for generic scripts. This means "Hello World" can now be written like this for LW11.5:

Code:
import lwsdk

lwMF = lwsdk.LWMessageFuncs()
lwMF.info("Presenting...", "Hello, World!")
 
I just wanted to say thanks for the overview and though it's a ton to absorb, I feel way better off exploring Python after watching the videos. A great resource to the Lightwave community!

I know the videos were made a while ago, but I only recently upgraded to LW 11.5 :D
 
Last edited:
I just wanted to say thanks for the overview and though it's a ton to absorb, I feel way better off exploring Python after watching the videos. A great resource to the Lightwave community!

I know the videos were made a while ago, but I only recently upgraded to LW 11.5 :D

Thanks!

Will more chapters to this video series be made?

I always intended to make more but I've been on other projects. I have to spend time learning before I can share info though.
 
Thanks for the update. I'm still trying to get my head wrapped around python and your videos are slowly helping the process for me.
 
Thank You, nice Job.

You did a really nice Job for us all. Thank you again.

I am very much the opinion, that this should have to come from the developers of the python-Integration (lwsdk).

But so we get a fine documentation too.
I am hard on the work to do some python script and I want to ask if there is interest in what I find out during my work. The documentation from NT is mainly stuff, that we could (most of it) get via the Pythons help command. We don't Need a documentation on the base: "Oh, look, we have implemented..." we Need more like: "Look we have implemented... and this way you can use it"
What I'am speeking of is... examples for the usage of the lwsdk, I'am not talking about python Basic-stuff... this should be found on python sites.
So my question is:
If my work is done and my Boss will give me some time to do so, than I would give the Information, that I did searched together bit for bit to the community. But only if there is interrest on it.
Even if I think, that this should have to come from NT.

Regards,
KANUSO
 
Last edited:
Hello and yes, there is definitely interest in any documentation for Python in LightWave.

I think some of the challenge for Python in LightWave is perception that the implementation is a bit more complex than was anticipated, initially.

Please share anything you come up with.
 
Hello BigHache,

I will post here because I want to help others in creating Python scripts and the most users are not aware that the nuArchitect bundle includes a GUI-Designer.

I don't have documentation created for the GUI things in LW-Python. But I do have a script created that can build Python-Scripts (the GUI part and its handling). The created scripts are ready to run and only the work of your choice has to be implemented. This includes all actual possible controls and even some extended usages of them. So you can create for example GFX-Buttons (a button with a picture on it instead of text). You can create complex GUI's even TAB-CTL in TAB-CTL is alowed. This script is part of the Python nuArchitect bundle. At the moment it uses libraries, that are part of nuArchitect. But if the interest is high enough, I will develope a stand alone Version. At the Moment you have to install the complete bundle to use nuGUIDesign script.

You can look at nuArchitect python version in this Forum. There you will find more Information about the nuArchitect bundle and nuGUIDesign.

Regards,
KANUSO
 
Back
Top