This repository has been archived on 2023-10-09. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
blender-archive/source/blender/include/BSE_seqeffects.h
Peter Schlaile c1b4132e8d == Sequencer ==
Major sequencer rewrite to add Speed Control effect.
Changes:
- Cleaned up large parts of sequence.c removing a lot of unnecessary code.
  (We first built old seqar array to decide, what is visible, then build
   dependencies with new code, then used old code to iterate through the
   strips and deciding using new code what is used and so forth and so on...)
  Should be much faster now.
- Now we build the strips recursively thereby elemenating the need of a
  seperate dependency calculation.
- Added a Speed-Control effect to change strip speed afterwards.
  (Offers global speed as well as IPO-controlled speed.
   There are several modes to play with:
   - Control by velocity (IPO = velocity where 1.0 is normal speed)
   - Control by frame number (IPO = target frame)
   - IPO-Value can be rescaled to frame-value, to make frame exact matching
     possible. (Matching video tracks to audio tracks with IPOs ;-)

Demo-Blend file is here http://peter.schlaile.de/blender/sequencer/speedcontroltest.blend

Since this was also a Plumiferos request I hope to be mentioned in the
credits ;-)

Enjoy! And please test the new sequencer thoroughly. It is really more like
a rewrite this time.
2006-11-11 22:35:40 +00:00

93 lines
2.9 KiB
C++

/**
* $Id$
*
* ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
*
* 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. The Blender
* Foundation also sells licenses for use in proprietary software under
* the Blender License. See http://www.blender.org/BL/ for information
* about this.
*
* 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.
*
* The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
* All rights reserved.
*
* The Original Code is: all of this file.
*
* Contributor(s): Peter Schlaile < peter [at] schlaile [dot] de >
*
* ***** END GPL/BL DUAL LICENSE BLOCK *****
*
*/
#ifndef BSE_SEQUENCE_EFFECTS_H
#define BSE_SEQUENCE_EFFECTS_H
/* Wipe effect */
enum {DO_SINGLE_WIPE, DO_DOUBLE_WIPE, DO_BOX_WIPE, DO_CROSS_WIPE,
DO_IRIS_WIPE,DO_CLOCK_WIPE};
struct Sequence;
struct ImBuf;
struct SeqEffectHandle {
/* constructors & destructor */
/* init & init_plugin are _only_ called on first creation */
void (*init)(struct Sequence *seq);
void (*init_plugin)(struct Sequence * seq, const char * fname);
/* number of input strips needed
(called directly after construction) */
int (*num_inputs)();
/* load is called first time after readblenfile in
get_sequence_effect automatically */
void (*load)(struct Sequence *seq);
/* duplicate */
void (*copy)(struct Sequence *dst, struct Sequence * src);
/* destruct */
void (*free)(struct Sequence *seq);
/* returns: -1: no input needed,
0: no early out,
1: out = ibuf1,
2: out = ibuf2 */
int (*early_out)(struct Sequence *seq,
float facf0, float facf1);
/* stores the default facf0 and facf1 if no IPO is present */
void (*get_default_fac)(struct Sequence * seq, int cfra,
float * facf0, float * facf1);
/* execute the effect
sequence effects are only required to either support
float-rects or byte-rects
(mixed cases are handled one layer up...) */
void (*execute)(struct Sequence *seq, int cfra,
float facf0, float facf1,
int x, int y,
struct ImBuf *ibuf1, struct ImBuf *ibuf2,
struct ImBuf *ibuf3, struct ImBuf *out);
};
struct SeqEffectHandle get_sequence_effect(struct Sequence * seq);
int get_sequence_effect_num_inputs(int seq_type);
void sequence_effect_speed_rebuild_map(struct Sequence * seq, int force);
#endif