No need to create special alpha mask when there's no opacity,

it defaults to the right mask.


svn path=/branches/work/kwin_composite/; revision=593452
icc-effect-5.14.5
Luboš Luňák 2006-10-07 21:19:23 +00:00
parent 06203d0652
commit 4d7a859bf3
1 changed files with 5 additions and 0 deletions

View File

@ -338,6 +338,11 @@ Picture SceneXrender::WindowData::alphaMask()
}
if( alpha != None )
return alpha;
if( effect.opacity == 1.0 )
{ // no need to create alpha mask
alpha_cached_opacity = 1.0;
return None;
}
Pixmap pixmap = XCreatePixmap( display(), rootWindow(), 1, 1, 8 );
XRenderPictFormat* format = XRenderFindStandardFormat( display(), PictStandardA8 );
XRenderPictureAttributes pa;