Sound Design Toolkit 075 Physically informed sound synthesis for everyday sounds

- Main Page
- Modules
- Data Structures
- Files

- File List

SDTMotor.h
1
19 #ifndef SDT_MOTOR_H
20 #define SDT_MOTOR_H
21
23 typedef struct SDTMotor SDTMotor;
24
27 extern SDTMotor *SDTMotor_new(long maxDelay);
28
31 extern void SDTMotor_free(SDTMotor *x);
32
36 extern void SDTMotor_setFilters(SDTMotor *x, double damp, double dc);
37
40 extern void SDTMotor_setRpm(SDTMotor *x, double f);
41
44 extern void SDTMotor_setThrottle(SDTMotor *x, double f);
45
47 extern void SDTMotor_setFourStroke(SDTMotor *x);
48
50 extern void SDTMotor_setTwoStroke(SDTMotor *x);
51
54 extern void SDTMotor_setNCylinders(SDTMotor *x, int i);
55
59 extern void SDTMotor_setCylinderSize(SDTMotor *x, double f);
60
65 extern void SDTMotor_setCompressionRatio(SDTMotor *x, double f);
66
69 extern void SDTMotor_setSparkTime(SDTMotor *x, double f);
70
73 extern void SDTMotor_setAsymmetry(SDTMotor *x, double f);
74
77 extern void SDTMotor_setBackfire(SDTMotor *x, double f);
78
81 extern void SDTMotor_setIntakeSize(SDTMotor *x, double f);
82
85 extern void SDTMotor_setExtractorSize(SDTMotor *x, double f);
86
89 extern void SDTMotor_setExhaustSize(SDTMotor *x, double f);
90
95 extern void SDTMotor_setExpansion(SDTMotor *x, double f);
96
99 extern void SDTMotor_setMufflerSize(SDTMotor *x, double f);
100
103 extern void SDTMotor_setMufflerFeedback(SDTMotor *x, double f);
104
107 extern void SDTMotor_setOutletSize(SDTMotor *x, double f);
108
116 extern void SDTMotor_dsp(SDTMotor *x, double *outs);
117
120 #endif
SDTMotor_setCylinderSize
void SDTMotor_setCylinderSize(SDTMotor *x, double f)
Sets the size of each single cylinder. The total volume of the engine is this value multiplied by the...
SDTMotor_setFourStroke
void SDTMotor_setFourStroke(SDTMotor *x)
Simulates the operation cycle of a four-stroke engine.
SDTMotor_setRpm
void SDTMotor_setRpm(SDTMotor *x, double f)
Sets the Revolutions Per Minute (RPM) of the engine.
SDTMotor_setMufflerFeedback
void SDTMotor_setMufflerFeedback(SDTMotor *x, double f)
Sets the amount of energy dissipated by the muffler chambers.
SDTMotor_new
SDTMotor * SDTMotor_new(long maxDelay)
Object constructor.
SDTMotor_setMufflerSize
void SDTMotor_setMufflerSize(SDTMotor *x, double f)
Sets the average length of the muffler chambers.
SDTMotor_setExhaustSize
void SDTMotor_setExhaustSize(SDTMotor *x, double f)
Sets the length of the main exhaust pipe.
SDTMotor_free
void SDTMotor_free(SDTMotor *x)
Object destructor.
SDTMotor_setTwoStroke
void SDTMotor_setTwoStroke(SDTMotor *x)
Simulates the operation cycle of a two-stroke engine.
SDTMotor_setNCylinders
void SDTMotor_setNCylinders(SDTMotor *x, int i)
Sets the number of cylinders in the engine block.
SDTMotor_setCompressionRatio
void SDTMotor_setCompressionRatio(SDTMotor *x, double f)
Sets the compression ratio of the engine. The compression ratio is computed dividing the cylinder vol...
SDTMotor_setIntakeSize
void SDTMotor_setIntakeSize(SDTMotor *x, double f)
Sets the average length of the intake pipes.
SDTMotor_setAsymmetry
void SDTMotor_setAsymmetry(SDTMotor *x, double f)
Sets the amount of irregularity in the operation cycle.
SDTMotor_dsp
void SDTMotor_dsp(SDTMotor *x, double *outs)
Signal processing routine. Call this function at sample rate to synthesize the engine sound...
SDTMotor_setThrottle
void SDTMotor_setThrottle(SDTMotor *x, double f)
Sets the throttle load.
SDTMotor_setOutletSize
void SDTMotor_setOutletSize(SDTMotor *x, double f)
Sets the length of the exhaust outlet.
SDTMotor_setSparkTime
void SDTMotor_setSparkTime(SDTMotor *x, double f)
Sets the width of the ignition pulse, compared to a full operation cycle.
SDTMotor_setBackfire
void SDTMotor_setBackfire(SDTMotor *x, double f)
Sets the amount of backfiring when the engine revs down.
SDTMotor
struct SDTMotor SDTMotor
Opaque data structure representing a combustion engine object.
Definition: SDTMotor.h:23
SDTMotor_setExpansion
void SDTMotor_setExpansion(SDTMotor *x, double f)
Sets the amount of expansion of the main exhaust pipe. This is a feature commonly found in two-stroke...
SDTMotor_setFilters
void SDTMotor_setFilters(SDTMotor *x, double damp, double dc)
Update filter coefficients. Should be always called after setting the sampling rate with SDT_setSampl...
SDTMotor_setExtractorSize
void SDTMotor_setExtractorSize(SDTMotor *x, double f)
Sets the average length of the extractor pipes.