X-Git-Url: http://research.m1stereo.tv/gitweb?a=blobdiff_plain;f=src%2Fmodules%2Fcore%2Ftransition_region.c;h=1bf836ee4377c1b20b5823c873a5e2070cc394c6;hb=64ae2085596a63af531253297fe915e7dbd17c88;hp=bfe4a4e1ddab8c6166fa6447726ab43bb4857b8e;hpb=5998e04fc78baf161cb12bd0e62254ed570b6b2b;p=melted diff --git a/src/modules/core/transition_region.c b/src/modules/core/transition_region.c index bfe4a4e..1bf836e 100644 --- a/src/modules/core/transition_region.c +++ b/src/modules/core/transition_region.c @@ -119,7 +119,7 @@ static uint8_t *filter_get_alpha_mask( mlt_frame this ) alpha = p; while ( size -- ) { - *p ++ = *image ++; + *p ++ = ( int )( ( ( *image ++ - 16 ) * 299 ) / 255 ); image ++; } mlt_properties_set_data( MLT_FRAME_PROPERTIES( this ), "alpha", alpha, region_width * region_height, mlt_pool_release, NULL ); @@ -176,7 +176,7 @@ static int transition_get_image( mlt_frame frame, uint8_t **image, mlt_image_for mlt_properties composite_properties = MLT_TRANSITION_PROPERTIES( composite ); // We want to ensure that we don't get a wobble... - mlt_properties_set_int( composite_properties, "distort", 1 ); + //mlt_properties_set_int( composite_properties, "distort", 1 ); mlt_properties_set_int( composite_properties, "progressive", 1 ); // Pass all the composite. properties on the transition down @@ -441,6 +441,9 @@ mlt_transition transition_region_init( void *arg ) // Resource defines the shape of the region mlt_properties_set( properties, "resource", arg == NULL ? "rectangle" : arg ); + + // Inform apps and framework that this is a video only transition + mlt_properties_set_int( properties, "_transition_type", 1 ); } // Return the transition