I have been having problems with trying to plot Trimmed NURBs surfaces obtained from standard IGES graphics files. Invariably there are several NURBs surfaces within an IGES file that contain errors that prevent the trimming process which is fine if the program can either ignore them or take action to fix them. Unfortunately my application just crashes at the fgluEndSurface() statement when trim curves are faulty. In order to reproduce this effect I have cobbled together an example using the IVF OpenGL Rings sample program. I created a simple NURBs surface with trim curve. When the trim curve is correctly orientated (counter clockwise) the program runs and displays the surface however if the trim curve orientation is reversed it crashes (in 64-bit only). I try to intercept with a callback but this does not seem to work or may be part of the cause of the crash. The message given is:
First-chance exception at 0x000007f88cd53ef8 in Rings.exe: 0xC0000028: An invalid or unaligned stack was encountered during an unwind operation.
Unhandled exception at 0x000007f88cd53ef8 in Rings.exe: 0xC0000028: An invalid or unaligned stack was encountered during an unwind operation.
The 32-bit configuration seems to ignore the error and the callback routine is not called.
Any help would be much appreciated.
Thanks in advance