[ODE] new to list, thoughts

Gary R. Van Sickle g.r.vansickle at worldnet.att.net
Mon May 30 23:32:11 MST 2005


> -----Original Message-----
> From: ode-bounces at q12.org [mailto:ode-bounces at q12.org] On 
> Behalf Of cr88192
> Sent: Sunday, May 29, 2005 10:50 PM
> To: ode at q12.org
> Subject: [ODE] new to list, thoughts
> 
[snip] 
> 
> another (more minor) issue is, imo, the use of a large number 
> of functions for getting/setting properties, vs the use of a 
> smaller set of functions with constants passed in indicating 
> the property being modified (sort of like opengl).
> 
> 
> ok, I just like opengl, and the api quite resembles opengl in 
> many ways, which is imo good, just a few things stand out as 
> somewhat un-gl-ish...
> 
> or am I missing something as to why it makes sense to design 
> the api this way?...

Well, I've seen it both ways, and I personally like the getter/setter
paradigm better than the
getter/setter-with-parameter-telling-what-to-get-or-set paradigm.  I can
think of a few non-subjective reasons to prefer the "non-OpenGL" way:

- Reduced stack usage (i.e. one less parameter to push on the stack and/or
eat up a register).
- Elimination of a runtime switch() or equivalent.
- Typesafe parameters.

-- 
Gary R. Van Sickle
 




More information about the ODE mailing list