/[svn]/libgig/trunk/src/gig.h
ViewVC logotype

Diff of /libgig/trunk/src/gig.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 515 by schoenebeck, Sat May 7 20:19:10 2005 UTC revision 666 by persson, Sun Jun 19 15:18:59 2005 UTC
# Line 314  namespace gig { Line 314  namespace gig {
314       *       *
315       * The function pointer argument has to be supplied with a valid       * The function pointer argument has to be supplied with a valid
316       * function of the given signature which will then be called on       * function of the given signature which will then be called on
317       * progress changes. The float argument of the callback function will       * progress changes. An equivalent progress_t structure will be passed
318       * then reflect the current progress as a value between 0.0 and 1.0.       * back as argument to the callback function on each progress change.
319         * The factor field of the supplied progress_t structure will then
320         * reflect the current progress as value between 0.0 and 1.0. You might
321         * want to use the custom field for data needed in your callback
322         * function.
323       */       */
324      struct progress_t {      struct progress_t {
325          void (*callback)(float); ///< Callback function pointer which has to be assigned to a function for progress notification.          void (*callback)(progress_t*); ///< Callback function pointer which has to be assigned to a function for progress notification.
326          float __range_min;          float factor;                  ///< Reflects current progress as value between 0.0 and 1.0.
327          float __range_max;          void* custom;                  ///< This pointer can be used for arbitrary data.
328            float __range_min;             ///< Only for internal usage, do not modify!
329            float __range_max;             ///< Only for internal usage, do not modify!
330          progress_t();          progress_t();
331      };      };
332    
# Line 437  namespace gig { Line 443  namespace gig {
443    
444              // Methods              // Methods
445              double GetVelocityAttenuation(uint8_t MIDIKeyVelocity);              double GetVelocityAttenuation(uint8_t MIDIKeyVelocity);
446                double GetVelocityRelease(uint8_t MIDIKeyVelocity);
447    
448          protected:          protected:
449              DimensionRegion(RIFF::List* _3ewl);              DimensionRegion(RIFF::List* _3ewl);
450             ~DimensionRegion();             ~DimensionRegion();
# Line 475  namespace gig { Line 483  namespace gig {
483              static uint              Instances;                  ///< Number of DimensionRegion instances.              static uint              Instances;                  ///< Number of DimensionRegion instances.
484              static VelocityTableMap* pVelocityTables;            ///< Contains the tables corresponding to the various velocity parameters (VelocityResponseCurve and VelocityResponseDepth).              static VelocityTableMap* pVelocityTables;            ///< Contains the tables corresponding to the various velocity parameters (VelocityResponseCurve and VelocityResponseDepth).
485              double*                  pVelocityAttenuationTable;  ///< Points to the velocity table corresponding to the velocity parameters of this DimensionRegion.              double*                  pVelocityAttenuationTable;  ///< Points to the velocity table corresponding to the velocity parameters of this DimensionRegion.
486                double*                  pVelocityReleaseTable;      ///< Points to the velocity table corresponding to the release velocity parameters of this DimensionRegion
487    
488              leverage_ctrl_t DecodeLeverageController(_lev_ctrl_t EncodedController);              leverage_ctrl_t DecodeLeverageController(_lev_ctrl_t EncodedController);
489                double* GetVelocityTable(curve_type_t curveType, uint8_t depth, uint8_t scaling);
490              double* CreateVelocityTable(curve_type_t curveType, uint8_t depth, uint8_t scaling);              double* CreateVelocityTable(curve_type_t curveType, uint8_t depth, uint8_t scaling);
491      };      };
492    
# Line 528  namespace gig { Line 538  namespace gig {
538              unsigned long        WorstCaseFrameSize;      ///< For compressed samples only: size (in bytes) of the largest possible sample frame.              unsigned long        WorstCaseFrameSize;      ///< For compressed samples only: size (in bytes) of the largest possible sample frame.
539              unsigned long        SamplesPerFrame;         ///< For compressed samples only: number of samples in a full sample frame.              unsigned long        SamplesPerFrame;         ///< For compressed samples only: number of samples in a full sample frame.
540              buffer_t             RAMCache;                ///< Buffers samples (already uncompressed) in RAM.              buffer_t             RAMCache;                ///< Buffers samples (already uncompressed) in RAM.
541                unsigned long        FileNo;                  ///< File number (> 0 when sample is stored in an extension file, 0 when it's in the gig)
542    
543              Sample(File* pFile, RIFF::List* waveList, unsigned long WavePoolOffset);              Sample(File* pFile, RIFF::List* waveList, unsigned long WavePoolOffset, unsigned long fileNo = 0);
544             ~Sample();             ~Sample();
545              /**              /**
546               * Swaps the order of the data words in the given memory area               * Swaps the order of the data words in the given memory area
# Line 714  namespace gig { Line 725  namespace gig {
725              void LoadSamples(progress_t* pProgress = NULL);              void LoadSamples(progress_t* pProgress = NULL);
726              void LoadInstruments(progress_t* pProgress = NULL);              void LoadInstruments(progress_t* pProgress = NULL);
727              friend class Region;              friend class Region;
728    
729                std::list<RIFF::File*> ExtensionFiles;
730      };      };
731    
732      /** Will be thrown whenever a gig specific error occurs while trying to access a Gigasampler File. */      /** Will be thrown whenever a gig specific error occurs while trying to access a Gigasampler File. */
# Line 723  namespace gig { Line 736  namespace gig {
736              void PrintMessage();              void PrintMessage();
737      };      };
738    
739        String libraryName();
740        String libraryVersion();
741    
742  } // namespace gig  } // namespace gig
743    
744  #endif // __GIG_H__  #endif // __GIG_H__

Legend:
Removed from v.515  
changed lines
  Added in v.666

  ViewVC Help
Powered by ViewVC