rework histogram_bezier, init wm icon set_icon(gg), update de.po+msg/txt
[goodguy/history.git] / cinelerra-5.1 / cinelerra / filevorbis.C
index 26b39119de61a1d124364afd6b0b178a266569b2..65eedf71a7f57cf7eeddd2e085562f408260bd7c 100644 (file)
@@ -2,21 +2,21 @@
 /*
  * CINELERRA
  * Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
- * 
+ *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- * 
+ *
  */
 
 #include "asset.h"
@@ -55,11 +55,9 @@ FileVorbis::~FileVorbis()
        close_file();
 }
 
-void FileVorbis::get_parameters(BC_WindowBase *parent_window, 
-       Asset *asset, 
-       BC_WindowBase* &format_window,
-       int audio_options,
-       int video_options)
+void FileVorbis::get_parameters(BC_WindowBase *parent_window,
+       Asset *asset, BC_WindowBase* &format_window,
+       int audio_options, int video_options, EDL *edl)
 {
        if(audio_options)
        {
@@ -151,9 +149,9 @@ int FileVorbis::open_file(int rd, int wr)
                                asset->audio_length = ov_pcm_total(&vf,-1);
 //printf("FileVorbis::open_file 1\n");
                                asset->audio_data = 1;
-// printf("FileVorbis::open_file 1 %d %d %d\n", 
-// asset->channels, 
-// asset->sample_rate, 
+// printf("FileVorbis::open_file 1 %d %d %d\n",
+// asset->channels,
+// asset->sample_rate,
 // asset->audio_length);
                        }
                }
@@ -170,19 +168,19 @@ int FileVorbis::open_file(int rd, int wr)
                {
                        vorbis_info_init(&vi);
                        if(!asset->vorbis_vbr)
-                               result = vorbis_encode_init(&vi, 
-                                       asset->channels, 
-                                       asset->sample_rate, 
-                                       asset->vorbis_max_bitrate, 
-                                       asset->vorbis_bitrate, 
+                               result = vorbis_encode_init(&vi,
+                                       asset->channels,
+                                       asset->sample_rate,
+                                       asset->vorbis_max_bitrate,
+                                       asset->vorbis_bitrate,
                                        asset->vorbis_min_bitrate);
                        else
                        {
                                result = vorbis_encode_setup_managed(&vi,
-                                       asset->channels, 
-                                       asset->sample_rate, 
-                                       asset->vorbis_max_bitrate, 
-                                       asset->vorbis_bitrate, 
+                                       asset->channels,
+                                       asset->sample_rate,
+                                       asset->vorbis_max_bitrate,
+                                       asset->vorbis_bitrate,
                                        asset->vorbis_min_bitrate);
                                result |= vorbis_encode_ctl(&vi, OV_ECTL_RATEMANAGE_AVG, NULL);
                                result |= vorbis_encode_setup_init(&vi);
@@ -199,14 +197,14 @@ int FileVorbis::open_file(int rd, int wr)
                                ogg_packet header;
                                ogg_packet header_comm;
                                ogg_packet header_code;
-                               vorbis_analysis_headerout(&vd, 
+                               vorbis_analysis_headerout(&vd,
                                        &vc,
                                        &header,
                                        &header_comm,
                                        &header_code);
                                ogg_stream_packetin(&os,
                                        &header);
-                               ogg_stream_packetin(&os, 
+                               ogg_stream_packetin(&os,
                                        &header_comm);
                                ogg_stream_packetin(&os,
                                        &header_code);
@@ -262,7 +260,7 @@ int FileVorbis::close_file_derived()
                        vorbis_info_clear(&vi);
                        fclose(fd);
                }
-               
+
                if(file->rd)
                {
 // This also closes the file handle.
@@ -300,8 +298,8 @@ int FileVorbis::read_samples(double *buffer, int64_t len)
 {
        if(!fd) return 0;
 
-// printf("FileVorbis::read_samples 1 %d %d %d %d\n", 
-// history_start, 
+// printf("FileVorbis::read_samples 1 %d %d %d %d\n",
+// history_start,
 // history_size,
 // file->current_sample,
 // len);
@@ -334,13 +332,13 @@ int FileVorbis::read_samples(double *buffer, int64_t len)
        }
 
 
-       read_history(buffer, 
-               file->current_sample, 
+       read_history(buffer,
+               file->current_sample,
                file->current_channel,
                len);
 
-// printf("FileVorbis::read_samples 2 %d %d %d %d\n", 
-// history_start, 
+// printf("FileVorbis::read_samples 2 %d %d %d %d\n",
+// history_start,
 // history_size,
 // file->current_sample,
 // len);