mirror of
https://github.com/game-stop/veejay.git
synced 2025-12-22 15:50:01 +01:00
Libvje / refactor : picnic
* w,h * clean headers
This commit is contained in:
@@ -22,15 +22,12 @@
|
|||||||
This effect uses libpostproc , it should be enabled at compile time
|
This effect uses libpostproc , it should be enabled at compile time
|
||||||
(--with-swscaler) if you want to use this Effect.
|
(--with-swscaler) if you want to use this Effect.
|
||||||
*/
|
*/
|
||||||
#include <stdint.h>
|
#include "common.h"
|
||||||
#include <stdlib.h>
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <libvjmem/vjmem.h>
|
#include <libvjmem/vjmem.h>
|
||||||
#include "picinpic.h"
|
|
||||||
#include <libyuv/yuvconv.h>
|
#include <libyuv/yuvconv.h>
|
||||||
#include <libavutil/pixfmt.h>
|
#include <libavutil/pixfmt.h>
|
||||||
#include <libel/avcommon.h>
|
#include "picinpic.h"
|
||||||
#include "common.h"
|
|
||||||
extern void vj_get_yuv444_template(VJFrame *src, int w, int h);
|
extern void vj_get_yuv444_template(VJFrame *src, int w, int h);
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
@@ -99,10 +96,12 @@ static int nearest_div(int val )
|
|||||||
return val;
|
return val;
|
||||||
}
|
}
|
||||||
|
|
||||||
void picinpic_apply( void *user_data, VJFrame *frame, VJFrame *frame2, int width, int height,
|
void picinpic_apply( void *user_data, VJFrame *frame, VJFrame *frame2,
|
||||||
int twidth, int theight, int x1, int y1 )
|
int twidth, int theight, int x1, int y1 )
|
||||||
{
|
{
|
||||||
int x, y;
|
int x, y;
|
||||||
|
const unsigned int width = frame->width;
|
||||||
|
const unsigned int height = frame->height;
|
||||||
pic_t *picture = (pic_t*) user_data;
|
pic_t *picture = (pic_t*) user_data;
|
||||||
int view_width = nearest_div(twidth);
|
int view_width = nearest_div(twidth);
|
||||||
int view_height = nearest_div(theight);
|
int view_height = nearest_div(theight);
|
||||||
|
|||||||
@@ -20,18 +20,9 @@
|
|||||||
|
|
||||||
#ifndef PICINPIC_H
|
#ifndef PICINPIC_H
|
||||||
#define PICINPIC_H
|
#define PICINPIC_H
|
||||||
|
vj_effect *picinpic_init( int w, int h );
|
||||||
#include <libvje/vje.h>
|
void picinpic_free(void *d);
|
||||||
#include <sys/types.h>
|
int picinpic_malloc( void **c, int w , int h );
|
||||||
#include <stdint.h>
|
void picinpic_apply( void *user_data, VJFrame *frame, VJFrame *frame2,
|
||||||
vj_effect *picinpic_init( int w, int h );
|
int twidth, int theight, int x1, int y1 );
|
||||||
|
|
||||||
void picinpic_free(void *d);
|
|
||||||
|
|
||||||
int picinpic_malloc( void **c, int w , int h );
|
|
||||||
|
|
||||||
|
|
||||||
void picinpic_apply( void *user_data, VJFrame *frame, VJFrame *frame2,
|
|
||||||
int w, int h, int twidth, int theight, int x1, int y1 );
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -476,10 +476,8 @@ extern void videoplay_apply(VJFrame *frame,VJFrame *B, int a, int b, int c);
|
|||||||
extern void videowall_apply(VJFrame *frame,VJFrame *B, int a, int b, int c, int d);
|
extern void videowall_apply(VJFrame *frame,VJFrame *B, int a, int b, int c, int d);
|
||||||
extern void flare_apply(VJFrame *frame, int type, int threshold, int radius );
|
extern void flare_apply(VJFrame *frame, int type, int threshold, int radius );
|
||||||
extern void constantblend_apply(VJFrame *frame, int type, int scale, int y );
|
extern void constantblend_apply(VJFrame *frame, int type, int scale, int y );
|
||||||
|
|
||||||
extern void picinpic_apply( void *user_data, VJFrame *frame, VJFrame *frame2,
|
extern void picinpic_apply( void *user_data, VJFrame *frame, VJFrame *frame2,
|
||||||
int twidth, int theight, int x1, int y1,
|
int x1, int y1, int width, int height);
|
||||||
int width, int height);
|
|
||||||
|
|
||||||
extern void threshold_apply( VJFrame *frame, VJFrame *frame2,int width, int height, int threshold, int reverse );
|
extern void threshold_apply( VJFrame *frame, VJFrame *frame2,int width, int height, int threshold, int reverse );
|
||||||
|
|
||||||
|
|||||||
@@ -603,8 +603,8 @@ static void vj_effman_apply_video_effect( VJFrame **frames, vjp_kf *todo_info,in
|
|||||||
arg[4], arg[5], arg[6]);
|
arg[4], arg[5], arg[6]);
|
||||||
break;
|
break;
|
||||||
case VJ_VIDEO_EFFECT_PICINPIC:
|
case VJ_VIDEO_EFFECT_PICINPIC:
|
||||||
picinpic_apply( vj_effects[entry]->user_data,frames[0], frames[1], frames[0]->width, frames[0]->height,
|
picinpic_apply( vj_effects[entry]->user_data,frames[0], frames[1],
|
||||||
arg[0], arg[1], arg[2], arg[3] );
|
arg[0], arg[1], arg[2], arg[3] );
|
||||||
break;
|
break;
|
||||||
case VJ_VIDEO_EFFECT_RIPPLETV:
|
case VJ_VIDEO_EFFECT_RIPPLETV:
|
||||||
water_apply( vj_effects[entry]->user_data,frames[0],frames[1],arg[0],arg[1],arg[2],arg[3],arg[4] );
|
water_apply( vj_effects[entry]->user_data,frames[0],frames[1],arg[0],arg[1],arg[2],arg[3],arg[4] );
|
||||||
|
|||||||
Reference in New Issue
Block a user