major changes to Region, AudioRegion, Playlist, AudioPlaylist and Crossfade state...
[ardour.git] / gtk2_ardour / editor_export_audio.cc
index 2a62f7a7512674ccf68d3b9f52cbfe71034895a4..fd40b9cae0f9af319b7bbcc23283c4167480b543 100644 (file)
@@ -55,7 +55,7 @@ void
 Editor::export_session()
 {
        if (session) {
-               export_range (0, session->current_end_frame());
+               export_range (session->current_start_frame(), session->current_end_frame());
        }
 }
 
@@ -74,7 +74,7 @@ Editor::export_selection ()
 }
 
 void
-Editor::export_range (jack_nframes_t start, jack_nframes_t end)
+Editor::export_range (nframes_t start, nframes_t end)
 {
        if (session) {
                if (export_dialog == 0) {
@@ -160,11 +160,11 @@ bool
 Editor::write_region (string path, boost::shared_ptr<AudioRegion> region)
 {
        boost::shared_ptr<AudioFileSource> fs;
-       const jack_nframes_t chunk_size = 4096;
-       jack_nframes_t to_read;
+       const nframes_t chunk_size = 4096;
+       nframes_t to_read;
        Sample buf[chunk_size];
        gain_t gain_buffer[chunk_size];
-       jack_nframes_t pos;
+       nframes_t pos;
        char s[PATH_MAX+1];
        uint32_t cnt;
        vector<boost::shared_ptr<AudioFileSource> > sources;
@@ -227,7 +227,7 @@ Editor::write_region (string path, boost::shared_ptr<AudioRegion> region)
        pos = region->position();
 
        while (to_read) {
-               jack_nframes_t this_time;
+               nframes_t this_time;
 
                this_time = min (to_read, chunk_size);
 
@@ -304,11 +304,11 @@ bool
 Editor::write_audio_range (AudioPlaylist& playlist, uint32_t channels, list<AudioRange>& range)
 {
        boost::shared_ptr<AudioFileSource> fs;
-       const jack_nframes_t chunk_size = 4096;
-       jack_nframes_t nframes;
+       const nframes_t chunk_size = 4096;
+       nframes_t nframes;
        Sample buf[chunk_size];
        gain_t gain_buffer[chunk_size];
-       jack_nframes_t pos;
+       nframes_t pos;
        char s[PATH_MAX+1];
        uint32_t cnt;
        string path;
@@ -357,7 +357,7 @@ Editor::write_audio_range (AudioPlaylist& playlist, uint32_t channels, list<Audi
                pos = (*i).start;
                
                while (nframes) {
-                       jack_nframes_t this_time;
+                       nframes_t this_time;
                        
                        this_time = min (nframes, chunk_size);
 
@@ -389,7 +389,7 @@ Editor::write_audio_range (AudioPlaylist& playlist, uint32_t channels, list<Audi
 
                        while (nframes) {
 
-                               jack_nframes_t this_time = min (nframes, chunk_size);
+                               nframes_t this_time = min (nframes, chunk_size);
                                memset (buf, 0, sizeof (Sample) * this_time);
 
                                for (uint32_t n=0; n < channels; ++n) {