* configure.ac: don't link with msimg32 directly has it isn't available on Win9x/NT4.

* modules/gui/skins2/win32/win32_graphics.cpp: use AlphaBlend() from the Win32Factory object.
This commit is contained in:
Gildas Bazin 2004-01-27 21:12:42 +00:00
parent 347fc3b2a4
commit 50ad1400d3
2 changed files with 11 additions and 7 deletions

View File

@ -1,5 +1,5 @@
dnl Autoconf settings for vlc
dnl $Id: configure.ac,v 1.163 2004/01/27 01:57:29 rocky Exp $
dnl $Id: configure.ac,v 1.164 2004/01/27 21:12:42 gbazin Exp $
AC_INIT(vlc,0.7.1-cvs)
@ -2788,7 +2788,7 @@ if test "${enable_skins2}" != "no"; then
ALIASES="${ALIASES} svlc"
AX_ADD_CPPFLAGS([skins2],[-U_OFF_T_ -U_off_t -Imodules/gui/skins2 -DWIN32_SKINS])
AX_ADD_CXXFLAGS([skins2],[-O2 -fno-rtti])
AX_ADD_LDFLAGS([skins2],[-loleaut32 -lwinspool -lwinmm -lshell32 -lctl3d32 -ladvapi32 -lwsock32 -lgdi32 -lcomdlg32 -lole32 -luuid -lcomctl32 -lmsimg32])
AX_ADD_LDFLAGS([skins2],[-loleaut32 -lwinspool -lwinmm -lshell32 -lctl3d32 -ladvapi32 -lwsock32 -lgdi32 -lcomdlg32 -lole32 -luuid -lcomctl32])
else
AX_ADD_PLUGINS([skins2])

View File

@ -2,7 +2,7 @@
* win32_graphics.cpp
*****************************************************************************
* Copyright (C) 2003 VideoLAN
* $Id: win32_graphics.cpp,v 1.2 2004/01/27 17:01:51 gbazin Exp $
* $Id: win32_graphics.cpp,v 1.3 2004/01/27 21:12:42 gbazin Exp $
*
* Authors: Cyril Deguet <asmax@via.ecp.fr>
* Olivier Teulière <ipkiss@via.ecp.fr>
@ -29,6 +29,7 @@
#define AC_SRC_ALPHA 1
#endif
#include "win32_factory.hpp"
#include "win32_graphics.hpp"
#include "win32_window.hpp"
#include "../src/generic_bitmap.hpp"
@ -179,13 +180,16 @@ void Win32Graphics::drawBitmap( const GenericBitmap &rBitmap,
bf.AlphaFormat = AC_SRC_ALPHA;
// Blend the image onto the internal DC
if( 1/*AlphaBlend*/ &&
!AlphaBlend( m_hDC, xDest, yDest, width, height, hDC, 0, 0,
width, height, bf ) )
BOOL (WINAPI *AlphaBlend)( HDC, int, int, int, int, HDC, int, int,
int, int, BLENDFUNCTION );
AlphaBlend = ((Win32Factory*)OSFactory::instance( getIntf() ))->AlphaBlend;
if( AlphaBlend &&
AlphaBlend( m_hDC, xDest, yDest, width, height, hDC, 0, 0,
width, height, bf ) )
{
msg_Err( getIntf(), "AlphaBlend() failed" );
}
else if( 1/*!AlphaBlend*/ )
else if( !AlphaBlend )
{
// Copy the image onto the internal DC
BitBlt( m_hDC, xDest, yDest, width, height, hDC, 0, 0, SRCCOPY );