Print Page | Close Window

Problem drawing bitmaps with alphachannel

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=15735
Printed Date: 22 February 2025 at 8:58am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Problem drawing bitmaps with alphachannel
Posted By: andolo
Subject: Problem drawing bitmaps with alphachannel
Date Posted: 27 November 2009 at 10:01am

Hi,

the following problem:

Drawing an image with semi-transparency (using alpha32 bitmaps / png) f.E. from the Styles works fine.
Now i am changeing some pixels to RGB values bigger than 0x80.

(f.E. COLOUR1 0x14001E is ok,  COLOUR2 RGB 0xFFCC00 shows wrong colour and no alpha, both with 30% alpha )
I can't properly draw an image containing pixels of COLOUR2 independent of the alpha channel.


remark: using the same image with CImageList::Draw works fine! Problem: I am unable to change the output size.


Am i using the wrong functions?  i use the following code:


// xtptoolkit 13.x
// class inherited from CXTPRibbonTheme -> calling CXTPOffice2007Theme::LoadImage


CXTPOffice2007Image* pImage = CXTPRibbonTheme::LoadImage(_T("RIBBONTABBACKGROUNDDWM"));         
pImage->DrawImage(pDC, rcDest, pImage->GetSource());



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net