/*
* 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
- *
+ *
*/
#ifndef GRADIENT_H
#include "guicast.h"
#include "loadbalance.h"
#include "overlayframe.inc"
-#include "cicolors.h"
+#include "bccolors.h"
#include "pluginvclient.h"
#include "thread.h"
#include "vframe.inc"
GradientConfig();
int equivalent(GradientConfig &that);
+ void reset();
void copy_from(GradientConfig &that);
- void interpolate(GradientConfig &prev,
- GradientConfig &next,
- long prev_frame,
- long next_frame,
+ void interpolate(GradientConfig &prev,
+ GradientConfig &next,
+ long prev_frame,
+ long next_frame,
long current_frame);
// Int to hex triplet conversion
int get_in_color();
class GradientShape : public BC_PopupMenu
{
public:
- GradientShape(GradientMain *plugin,
+ GradientShape(GradientMain *plugin,
GradientWindow *gui,
- int x,
+ int x,
int y);
void create_objects();
static char* to_text(int shape);
class GradientRate : public BC_PopupMenu
{
public:
- GradientRate(GradientMain *plugin,
- int x,
+ GradientRate(GradientMain *plugin,
+ int x,
int y);
void create_objects();
static char* to_text(int shape);
GradientWindow *window;
};
+class GradientReset : public BC_GenericButton
+{
+public:
+ GradientReset(GradientMain *plugin, GradientWindow *window, int x, int y);
+ int handle_event();
+ GradientMain *plugin;
+ GradientWindow *window;
+};
+
-class GradientInColorThread : public ColorThread
+class GradientInColorThread : public ColorPicker
{
public:
GradientInColorThread(GradientMain *plugin, GradientWindow *window);
};
-class GradientOutColorThread : public ColorThread
+class GradientOutColorThread : public ColorPicker
{
public:
GradientOutColorThread(GradientMain *plugin, GradientWindow *window);
public:
GradientWindow(GradientMain *plugin);
~GradientWindow();
-
+
void create_objects();
void update_in_color();
void update_out_color();
+ void update_gui();
void update_shape();
+ void done_event(int result);
GradientMain *plugin;
BC_Title *angle_title;
GradientOutRadius *out_radius;
GradientInColorButton *in_color;
GradientOutColorButton *out_color;
+ GradientReset *reset;
GradientInColorThread *in_color_thread;
GradientOutColorThread *out_color_thread;
GradientShape *shape;
void process_package(LoadPackage *package);
GradientServer *server;
GradientMain *plugin;
- YUV yuv;
};
class GradientServer : public LoadServer