Changeset 603

Show
Ignore:
Timestamp:
10/28/08 20:01:05 (2 months ago)
Author:
wolke
Message:

some new sample featurs

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/new_fx_rack_and_sample_fun/libs/hydrogen/include/hydrogen/sample.h

    r127 r603  
    3838{ 
    3939public: 
    40         Sample( unsigned frames, const QString& filename, float* data_L = NULL, float* data_R = NULL ); 
     40        Sample( unsigned frames, 
     41                const QString& filename,  
     42                float* data_L = NULL, 
     43                float* data_R = NULL, 
     44                const QString& sample_mode = "normal", 
     45                unsigned fade_out_startframe = -1, 
     46                int repeats = -1, 
     47                unsigned start_frame = -1, 
     48                unsigned loop_frame = -1, 
     49                unsigned end_frame = -1); 
     50                 
     51 
    4152        ~Sample(); 
    4253 
     
    7687        QString __filename;             ///< filename associated with this sample 
    7788        unsigned __n_frames;            ///< Total number of frames in this sample. 
     89        QString __sample_mode;          ///< loop mode 
     90        unsigned __fade_out_startframe; ///< start frame for fade out 
     91        int __repeats;                  ///< repats from the loop section 
     92        unsigned __start_frame;         ///< start frame 
     93        unsigned __loop_frame;          ///< beginn of the loop section 
     94        unsigned __end_frame;           ///< sample end frame 
    7895 
    7996        //static int __total_used_bytes; 
  • branches/new_fx_rack_and_sample_fun/libs/hydrogen/src/sample.cpp

    r419 r603  
    3434{ 
    3535 
    36 Sample::Sample( unsigned frames, const QString& filename, float* data_l, float* data_r ) 
     36Sample::Sample( unsigned frames, 
     37                const QString& filename,  
     38                float* data_l, 
     39                float* data_r, 
     40                const QString& sample_mode, 
     41                unsigned fade_out_startframe, 
     42                int repeats, 
     43                unsigned start_frame, 
     44                unsigned loop_frame, 
     45                unsigned end_frame  ) 
     46 
    3747                : Object( "Sample" ) 
    3848                , __data_l( data_l ) 
     
    4151                , __filename( filename ) 
    4252                , __n_frames( frames ) 
     53                , __sample_mode( sample_mode ) 
     54                , __fade_out_startframe( fade_out_startframe ) 
     55                , __repeats( repeats ) 
     56                , __start_frame( start_frame ) 
     57                , __loop_frame( loop_frame ) 
     58                , __end_frame( end_frame )  
    4359{ 
    4460                //INFOLOG("INIT " + m_sFilename + ". nFrames: " + toString( nFrames ) );