Page 1 of 1

[OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Aug 16, 2019 4:34 pm
by JeremyaFr
Hello,
Here is a tool to fix shading of X-Wing Alliance's OPT files.

Download link:
https://github.com/JeremyAnsel/XwaOpter/releases/latest

Credits:
- Ooc for XWA Opter v1
- Jérémy Ansel (JeremyaFr) for XWA Opter v2

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Aug 16, 2019 5:43 pm
by blue_max
Is this shading fix related to the 32-bit mode hook?
EDIT: No: it re-computes the normals of the surfaces so that the shading is computed properly in-game. Correct?

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Aug 16, 2019 5:50 pm
by Darksaber
No, it's a tool that has been around for years, I asked Jeremy if it was possible to updated and fix a few problems with the original, and he did just that :)

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Feb 07, 2020 12:39 pm
by JeremyaFr
UPDATE

You can now enter the normals threshold.

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Feb 07, 2020 4:05 pm
by Vince T
Just thinking of something: could the threshold be defined on an individual per-mesh level? Especially for Star Destroyer-shaped ships where angles between left and right side may be just as wide as between the left ans side of the engines? In case of the former, the mesh shading shouldn‘t be smoothed while with the latter it should....

This would probably require a complete reconstruction of the tool if not the OPT structure itself. Just I‘d throw in the thought ....

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Feb 07, 2020 5:25 pm
by JeremyaFr
Hello,
Here is a quick update.

EDIT: link removed

You can select the whole OPT or just 1 mesh.

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Feb 07, 2020 5:27 pm
by blue_max
General_Trageton wrote:
Fri Feb 07, 2020 4:05 pm
Just thinking of something: could the threshold be defined on an individual per-mesh level?
I would expect your modelling software already does something like this? For instance, Blender allows you to specify the smooth threshold on a per-face basis, if necessary. Doesn't that work?

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Feb 07, 2020 7:47 pm
by Vince T
Not using blender and I currently don't have the time or patience to learn it.

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Feb 07, 2020 8:50 pm
by blue_max
General_Trageton wrote:
Fri Feb 07, 2020 7:47 pm
Not using blender and I currently don't have the time or patience to learn it.
Right, I understand that, I was just suggesting that maybe the 3D editing program that you use may already do something similar.

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Feb 07, 2020 8:54 pm
by Trevor
Are not normals lost on import - hence the very reason for this program?

Software can sometimes merge verticies even if they have different normals, I assume this program re-calculates and then keeps said verticies split so that XWA renders properly.

Trev

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Feb 07, 2020 11:31 pm
by Vince T
I'm using Rhino and exporting the models as dxf. So yeah either during the exporting or the import into OPTech the normals are lost and I usually recalculate everything.

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Sat Feb 08, 2020 12:23 am
by blue_max
If it helps, it looks like exporting to OBJ and then importing into XwaOptEditor keeps the normals.

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Sat Feb 08, 2020 9:42 am
by JeremyaFr
OPTech can also import OBJ files with normals.

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Sat Feb 08, 2020 11:17 am
by Trevor
Nice to know

Solution in an8 for ISD hull vs engine cone - flat vs smooth is to assign a smooth angle of minimum angle required for smooth objects and to "detach" the left hand side of the main hull from the right and re-merge mesh (to keep same mesh count)

Trev

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Fri Feb 14, 2020 1:07 pm
by JeremyaFr
UPDATE

Hello,
I've merged the WIP version into the stable version.

Re: [OPTing] Xwa Opter (Opt Fix) v2

Posted: Sat Aug 01, 2020 7:01 pm
by JeremyaFr
UPDATE

Hello,
I've updated XwaOpter.

Now the tool remembers the file dialog last directory.
The directory path is stored in a file named "XwaOpter.cfg".