mirror of
https://github.com/game-stop/veejay.git
synced 2025-12-19 14:19:58 +01:00
pencil sketch minor optimize, prefix frei0r and freeframe plugins
git-svn-id: svn://code.dyne.org/veejay/trunk@758 eb8d1916-c9e9-0310-b8de-cf0c9472ead5
This commit is contained in:
@@ -178,7 +178,6 @@ void pencilsketch_apply(
|
|||||||
m = m + d;
|
m = m + d;
|
||||||
/* a magical forumula to combine the pixel with the original*/
|
/* a magical forumula to combine the pixel with the original*/
|
||||||
y = ((((y << 1) - (255 - m))>>1) + Y[i])>>1;
|
y = ((((y << 1) - (255 - m))>>1) + Y[i])>>1;
|
||||||
// if(y < 16) y = 16; else if (y>240) y = 240;
|
|
||||||
/* apply blend operation on masked pixel */
|
/* apply blend operation on masked pixel */
|
||||||
Y[i] = _pff(y,yb,threshold_max);
|
Y[i] = _pff(y,yb,threshold_max);
|
||||||
}
|
}
|
||||||
@@ -192,11 +191,8 @@ void pencilsketch_apply(
|
|||||||
|
|
||||||
if(type != 7) /* all b/w sketches */
|
if(type != 7) /* all b/w sketches */
|
||||||
{
|
{
|
||||||
for(i=0; i < uv_len; i++)
|
veejay_memset( Cb, 0, uv_len );
|
||||||
{
|
veejay_memset( Cr, 0, uv_len );
|
||||||
Cb[i] = 128;
|
|
||||||
Cr[i] = 128;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else /* all colour sketches */
|
else /* all colour sketches */
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -312,7 +312,9 @@ static void* deal_with_fr( void *handle, char *name)
|
|||||||
if( r_params > 8 )
|
if( r_params > 8 )
|
||||||
r_params = 8;
|
r_params = 8;
|
||||||
|
|
||||||
char *plug_name = strdup( finfo.name );
|
char new_name[512];
|
||||||
|
sprintf(new_name, "Frei0r %s", finfo.name );
|
||||||
|
char *plug_name = strdup( new_name );
|
||||||
vevo_property_set( port, "n_params", VEVO_ATOM_TYPE_INT, 1, &r_params );
|
vevo_property_set( port, "n_params", VEVO_ATOM_TYPE_INT, 1, &r_params );
|
||||||
vevo_property_set( port, "f0r_p", VEVO_ATOM_TYPE_INT,1, &n_params );
|
vevo_property_set( port, "f0r_p", VEVO_ATOM_TYPE_INT,1, &n_params );
|
||||||
vevo_property_set( port, "name", VEVO_ATOM_TYPE_STRING,1, &plug_name );
|
vevo_property_set( port, "name", VEVO_ATOM_TYPE_STRING,1, &plug_name );
|
||||||
@@ -351,7 +353,9 @@ static void* deal_with_ff( void *handle, char *name )
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
plugin_name = strdup( pis->pluginName );
|
char new_name[512];
|
||||||
|
sprintf(new_name, "FreeFrame %s", pis->pluginName );
|
||||||
|
plugin_name = strdup( new_name );
|
||||||
if ( (q(FF_INITIALISE, NULL, 0 )).ivalue == FF_FAIL )
|
if ( (q(FF_INITIALISE, NULL, 0 )).ivalue == FF_FAIL )
|
||||||
{
|
{
|
||||||
veejay_msg(VEEJAY_MSG_ERROR, "Cannot call init()");
|
veejay_msg(VEEJAY_MSG_ERROR, "Cannot call init()");
|
||||||
|
|||||||
Reference in New Issue
Block a user