olaf neophyte and de.po updates, valgrind tweaks, delete green lady, inkscape dpi=96
[goodguy/history.git] / cinelerra-5.1 / cinelerra / filejpeglist.C
index 4594713b0a44fe30d388c7e2d2933f93eb10cf3c..d1c7ba9f8ae974408d974fd13643054e33ded353 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 "assets.h"
@@ -54,11 +54,9 @@ char* FileJPEGList::extension()
        return ".jpg";
 }
 
-void FileJPEGList::get_parameters(BC_WindowBase *parent_window, 
-       Asset *asset, 
-       BC_WindowBase* &format_window,
-       int audio_options,
-       int video_options)
+void FileJPEGList::get_parameters(BC_WindowBase *parent_window,
+       Asset *asset, BC_WindowBase* &format_window,
+       int audio_options, int video_options, EDL *edl)
 {
        if(video_options)
        {
@@ -102,19 +100,11 @@ int FileJPEGList::read_frame(VFrame *frame, VFrame *data)
 {
        PRINT_TRACE
 
-       mjpeg_t *mjpeg = mjpeg_new(asset->width, 
-               asset->height, 
-               1);
-       mjpeg_decompress(mjpeg, 
-               data->get_data(), 
-               data->get_compressed_size(),
-               0,  
-               frame->get_rows(), 
-               frame->get_y(), 
-               frame->get_u(), 
-               frame->get_v(),
-               frame->get_color_model(),
-               file->cpus);
+       mjpeg_t *mjpeg = mjpeg_new(asset->width, asset->height, 1);
+       mjpeg_decompress(mjpeg, data->get_data(), data->get_compressed_size(),
+               0, frame->get_rows(),
+               frame->get_y(), frame->get_u(), frame->get_v(),
+               frame->get_color_model(), file->cpus);
        mjpeg_delete(mjpeg);
        PRINT_TRACE
        return 0;
@@ -122,16 +112,10 @@ int FileJPEGList::read_frame(VFrame *frame, VFrame *data)
 
 int FileJPEGList::write_frame(VFrame *frame, VFrame *data)
 {
-       mjpeg_t *mjpeg = mjpeg_new(asset->width, 
-               asset->height, 
-               1);
-       mjpeg_compress(mjpeg, 
-               frame->get_rows(), 
-               frame->get_y(), 
-               frame->get_u(), 
-               frame->get_v(),
-               frame->get_color_model(),
-               file->cpus);
+       mjpeg_t *mjpeg = mjpeg_new(asset->width, asset->height, 1);
+       mjpeg_compress(mjpeg, frame->get_rows(),
+               frame->get_y(), frame->get_u(), frame->get_v(),
+               frame->get_color_model(), file->cpus);
        data->allocate_compressed_data(mjpeg_output_size(mjpeg));
        bcopy(mjpeg_output_buffer(mjpeg), frame->get_data(), mjpeg_output_size(mjpeg));
        mjpeg_delete(mjpeg);
@@ -139,21 +123,11 @@ int FileJPEGList::write_frame(VFrame *frame, VFrame *data)
 }
 
 
-
-
-
-
-
-
-
-
-
 JPEGConfigVideo::JPEGConfigVideo(BC_WindowBase *parent_window, Asset *asset)
  : BC_Window(_(PROGRAM_NAME ": Video Compression"),
        parent_window->get_abs_cursor_x(),
        parent_window->get_abs_cursor_y(),
-       400,
-       100)
+       400, 100)
 {
        this->parent_window = parent_window;
        this->asset = asset;
@@ -168,17 +142,9 @@ void JPEGConfigVideo::create_objects()
        int x = 10, y = 10;
        lock_window("JPEGConfigVideo::create_objects");
        add_subwindow(new BC_Title(x, y, _("Quality:")));
-       add_subwindow(new BC_ISlider(x + 80, 
-               y,
-               0,
-               200,
-               200,
-               0,
-               100,
-               asset->quality,
-               0,
-               0,
-               &asset->quality));
+       add_subwindow(new BC_ISlider(x + 80, y, 0,
+               200, 200, 0, 100, asset->quality,
+               0, 0, &asset->quality));
 
        add_subwindow(new BC_OKButton(this));
        unlock_window();
@@ -190,9 +156,3 @@ int JPEGConfigVideo::close_event()
        return 1;
 }
 
-
-
-
-
-
-