View Full Version : Manually *SETTING* Vertex Normals through maxscript
04-22-2010, 08:15 AM
I've been designing a maxscript importer to import game models. This particular model format stores vertex normals for its shading. Now I realise max recomputes its vertex normals everytime you render, which is such an annoying bug, and offers no easy way to simply lock vertex normals after you manually set them.
I've googled this problem endlessly and can't seem to find a fix. I see alot of problems getting vertex normals 3ds max, but there doesn't seem to be much in the way of setting vertex normals in max. I realise I must go through the Edit_Normals modifier, but how would I apply a pre-computed vertex normal to a vertex in maxscript? Any help on this would be highly appreciated as I've been stuck on this problem for quite some time. Thank you for your help and support.
04-27-2010, 02:09 PM
I also working around export/import scripts.
Maybe you would like to exchange experiences.
Here is my MSN: email@example.com
04-27-2010, 03:05 PM
You can set vertex normals with both mesh and edit_normals search the maxscript help for *setnormal* it will require a vertex/normal id (mesh objects expect a vertex id, while edit_normals expects a normal id) as well as point3 normal direction. With Edit_Normals you can also set normals to explicit or specified:
Specified: These are normals that are intended for use by particular corners of particular faces, without regard to smoothing groups. For instance, you might create a box, apply Edit Normals, select a group of normals at a particular vertex, and click Unify. Now those three faces are told specifically to use that one unified normal, and they ignore their smoothing groups at that vertex. But specified normals are not set to explicit values; they ignore smoothing groups, but they're still based on the face normals of the faces that use them. Specified normals are displayed as cyan.
Explicit: These are normals that are set to particular values. For instance, if you use the Move or Rotate command to change a normal from its default value, it has to be made explicit, so it won't be recomputed based on the face normals. Explicit normals are green by default. Note Explicit normals are also considered to be specified.
04-27-2010, 03:05 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©2000-2014, Jelsoft Enterprises Ltd.