Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Suspension subclassing; CARSUSPENSIONINFO struct.
11-18-2010, 12:59 AM,
#1
Suspension subclassing; CARSUSPENSIONINFO struct.
As hinted to in the Car graphics config thread ( http://vdrift.net/Forum/viewtopic.php?p=11414#11414 ), I have been working expanding the scope of suspension types simulation. Of particular interest to me is double wishbone suspension which some of you may realise cannot properly be simulated with a single hinge point, being described by an offset pair of additive sine curves (or, in other words, two circles, as opposed to the one that is available right now.

Anyway. For various reasons relating to doing things the "right" way, I'm trying to put this together with some supposedly straightforward polymorphism.
It now makes sense for CARDYNAMICS to contain not a vector of CARSUSPENSION but pointers there to (because you need pointers or references in C++ and you can't uses references like that). Easy to deal with — except that it buggers up the joeserialize stuff. I'm not entirely sure what joeserialize is supposed to achieve, but simpling preventing the suspension for being serialized doesn't seem to cause any problems.... Someone tell me if this is bad and will leak memory or something?
Moving on, I'm also interested in what the point of having a CARSUSPENSIONINFO struct is? In the interest of reducing the number of data types that need to be derived, is there a problem with storing that data directly in the CARSUSPENSION class (and derivates)?
Reply


Messages In This Thread
Suspension subclassing; CARSUSPENSIONINFO struct. - by fudje - 11-18-2010, 12:59 AM
[No subject] - by NaN - 11-18-2010, 11:04 AM
[No subject] - by fudje - 11-18-2010, 07:11 PM
[No subject] - by fudje - 11-18-2010, 08:02 PM
[No subject] - by fudje - 11-19-2010, 12:39 AM
[No subject] - by NaN - 11-19-2010, 01:13 PM
[No subject] - by NaN - 11-19-2010, 02:28 PM
[No subject] - by fudje - 11-19-2010, 04:20 PM
Patch for LE data. - by fudje - 11-20-2010, 01:08 AM
[No subject] - by fudje - 11-20-2010, 01:55 AM
[No subject] - by fudje - 11-20-2010, 04:19 AM
[No subject] - by NaN - 11-20-2010, 07:41 AM
[No subject] - by fudje - 11-20-2010, 03:41 PM
[No subject] - by fudje - 11-21-2010, 04:46 AM
[No subject] - by NaN - 11-21-2010, 07:32 AM
[No subject] - by NaN - 11-21-2010, 07:36 AM
[No subject] - by fudje - 11-21-2010, 11:30 AM
[No subject] - by joevenzon_phpbb2_import3 - 11-21-2010, 02:20 PM
[No subject] - by fudje - 11-21-2010, 09:02 PM
[No subject] - by fudje - 11-22-2010, 07:51 PM
[No subject] - by fudje - 11-26-2010, 01:24 AM
[No subject] - by NaN - 11-26-2010, 07:53 PM
More stuff - by fudje - 12-01-2010, 06:08 AM
[No subject] - by NaN - 12-01-2010, 12:59 PM

Forum Jump:


Users browsing this thread: 2 Guest(s)