Subject: [Nel] Exporter plugin for 3DSMAX 4.0

From: "Valerio Santinelli" <[email-masked]>
Date: Wed, 3 Oct 2001 15:25:16 +0200

Is there anybody on the list who successfully compiled the exporter plugin with 3DSMAX 4.0 SDK?
I'm getting lots of errors because of the use of templates like min(), max(), etc.. that are in the standard MS ATL, but it seems that they're not supported by STLPort?!

--
Valerio Santinelli
HateSeed.com Founder (http://www.hateseed.com)
In Flames Italia Webmaster (http://www.inflames.it)
My Lab (http://tanis.hateseed.com)

---

From: "Cyril 'Hulud' Corvazier" <[email-masked]>
Date: Wed, 3 Oct 2001 16:06:38 +0200

Hello,

First, thank for this report.

>C:\3dsmax4\maxsdk\Include\box2.h(34) : error C2065: 'min' : undeclared 
>identifier

Errors with min are present with the 3dsmax 3.0 sdk too.

Windows standard headers define min and max.
STLPort standard headers don't define min and max but std::min and std::max.
The way we have solved the problem is to add manually the following code :

#ifndef min
#define min(a,b)            (((a) < (b)) ? (a) : (b))
#endif min

in the header box2.h from 3dsmax sdk. I hope it works for max4. Not very nice but.. :-)

>C:\Programmi\Microsoft Visual 
>Studio\MyProjects\nevrax\code\nel\tools\3d\plugin_max\nel_patch_lib\nel_patch_me
>sh.cpp(341) : error C2039: 'patch2' : is not a member of 'PatchEdge'
>        C:\3dsmax4\maxsdk\Include\patch.h(183) : see declaration of 'PatchEdge'

In max3 sdk, the PatchEdge has this two members :

int patch1;
int patch2;

Patch1 is the number of the first patch that share the edge, Patch2 is the number of the second patch that share that edge, <0 if it is an open edge.
It seems that this members don't exist any more under max4 sdk. You should take a look in your max4 sdk documentation and make a fix in the 
plugin code to work with the new PatchEdge class.

If you really don't know how to do this, make a post in the list :-).

Regards,

Cyril Corvazier
---
Lead 3d programmer
Nevrax France

---

From: "Valerio Santinelli" <[email-masked]>
Date: Wed, 3 Oct 2001 16:56:03 +0200

I'm going to try to do this tonight. I'll let you know.

--
Valerio Santinelli
http://www.digisoft-multimedia.it/

  ----- Original Message ----- 
  From: Cyril 'Hulud' Corvazier 
  To: [email-masked] 
  Sent: Wednesday, October 03, 2001 4:06 PM
  Subject: Re: [Nel] Exporter plugin for 3DSMAX 4.0

  Hello,

  #ifndef min

  int patch1;
  int patch2;

  Regards,

  Cyril Corvazier
  ---
  Lead 3d programmer
  Nevrax France