/[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 3198 by schoenebeck, Sun May 21 12:46:05 2017 UTC revision 3323 by schoenebeck, Thu Jul 20 22:09:54 2017 UTC
# Line 61  Line 61 
61  # define CHUNK_ID_SCRI  0x53637269 // own gig format extension  # define CHUNK_ID_SCRI  0x53637269 // own gig format extension
62  # define CHUNK_ID_LSNM  0x4c534e4d // own gig format extension  # define CHUNK_ID_LSNM  0x4c534e4d // own gig format extension
63  # define CHUNK_ID_SCSL  0x5343534c // own gig format extension  # define CHUNK_ID_SCSL  0x5343534c // own gig format extension
64    # define CHUNK_ID_LSDE  0x4c534445 // own gig format extension
65  #else  // little endian  #else  // little endian
66  # define LIST_TYPE_3PRG 0x67727033  # define LIST_TYPE_3PRG 0x67727033
67  # define LIST_TYPE_3EWL 0x6C776533  # define LIST_TYPE_3EWL 0x6C776533
# Line 79  Line 80 
80  # define CHUNK_ID_SCRI  0x69726353 // own gig format extension  # define CHUNK_ID_SCRI  0x69726353 // own gig format extension
81  # define CHUNK_ID_LSNM  0x4d4e534c // own gig format extension  # define CHUNK_ID_LSNM  0x4d4e534c // own gig format extension
82  # define CHUNK_ID_SCSL  0x4c534353 // own gig format extension  # define CHUNK_ID_SCSL  0x4c534353 // own gig format extension
83    # define CHUNK_ID_LSDE  0x4544534c // own gig format extension
84  #endif // WORDS_BIGENDIAN  #endif // WORDS_BIGENDIAN
85    
86  #ifndef GIG_DECLARE_ENUM  #ifndef GIG_DECLARE_ENUM
# Line 378  namespace gig { Line 380  namespace gig {
380          file_offset_t loop_cycles_left;  ///< How many times the loop has still to be passed, this value will be decremented with each loop cycle.          file_offset_t loop_cycles_left;  ///< How many times the loop has still to be passed, this value will be decremented with each loop cycle.
381      };      };
382    
383        /**
384         * Defines behavior options for envelope generators.
385         *
386         * These options allow to override the precise default behavior of the
387         * envelope generators' state machines.
388         *
389         * @b Note: These EG options are an extension to the original gig file
390         * format, so these options are not available with the original
391         * Gigasampler/GigaStudio software! Currently only LinuxSampler and gigedit
392         * support these EG options!
393         *
394         * Adding these options to the original gig file format was necessary,
395         * because the precise state machine behavior of envelope generators of the
396         * gig format (and thus the default EG behavior if not explicitly overridden
397         * here) deviates from common, expected behavior of envelope generators in
398         * general, if i.e. compared with EGs of hardware synthesizers. For example
399         * with the gig format, the attack and decay stages will be aborted as soon
400         * as a note-off is received. Most other EG implementations in the industry
401         * however always run the attack and decay stages to their full duration,
402         * even if an early note-off arrives. The latter behavior is intentionally
403         * implemented in most other products, because it is required to resemble
404         * percussive sounds in a realistic manner.
405         */
406        struct eg_opt_t {
407            bool AttackCancel;     ///< Whether the "attack" stage is cancelled when receiving a note-off (default: @c true).
408            bool AttackHoldCancel; ///< Whether the "attack hold" stage is cancelled when receiving a note-off (default: @c true).
409            bool DecayCancel;      ///< Whether the "decay" stage is cancelled when receiving a note-off (default: @c true).
410            bool ReleaseCancel;    ///< Whether the "release" stage is cancelled when receiving a note-on (default: @c true).
411    
412            eg_opt_t();
413            void serialize(Serialization::Archive* archive);
414        };
415    
416      // just symbol prototyping      // just symbol prototyping
417      class File;      class File;
418      class Instrument;      class Instrument;
# Line 516  namespace gig { Line 551  namespace gig {
551              uint16_t           SampleStartOffset;             ///< Number of samples the sample start should be moved (0 - 2000).              uint16_t           SampleStartOffset;             ///< Number of samples the sample start should be moved (0 - 2000).
552              double             SampleAttenuation;             ///< Sample volume (calculated from DLS::Sampler::Gain)              double             SampleAttenuation;             ///< Sample volume (calculated from DLS::Sampler::Gain)
553              uint8_t            DimensionUpperLimits[8];       ///< gig3: defines the upper limit of the dimension values for this dimension region. In case you wondered why this is defined on DimensionRegion level and not on Region level: the zone sizes (upper limits) of the velocity dimension can indeed differ in the individual dimension regions, depending on which zones of the other dimension types are currently selected. So this is exceptional for the velocity dimension only. All other dimension types have the same dimension zone sizes for every single DimensionRegion (of the sample Region).              uint8_t            DimensionUpperLimits[8];       ///< gig3: defines the upper limit of the dimension values for this dimension region. In case you wondered why this is defined on DimensionRegion level and not on Region level: the zone sizes (upper limits) of the velocity dimension can indeed differ in the individual dimension regions, depending on which zones of the other dimension types are currently selected. So this is exceptional for the velocity dimension only. All other dimension types have the same dimension zone sizes for every single DimensionRegion (of the sample Region).
554                eg_opt_t           EGOptions;                     ///< [gig extension]: Behavior options which should be used for all 3 envelope generators.
555    
556              // derived attributes from DLS::Sampler              // derived attributes from DLS::Sampler
557              using DLS::Sampler::UnityNote;              using DLS::Sampler::UnityNote;

Legend:
Removed from v.3198  
changed lines
  Added in v.3323

  ViewVC Help
Powered by ViewVC