Xtreme Visual Basic Talk

Xtreme Visual Basic Talk (http://www.xtremevbtalk.com/)
-   Managed DirectX (http://www.xtremevbtalk.com/managed-directx/)
-   -   colorkeying (http://www.xtremevbtalk.com/managed-directx/310423-colorkeying.html)

jimseng 09-10-2009 10:17 AM

In direct draw there is a ColorSpaceHighValue and ColorSpaceLowValue for setting a range of colours to key. I have managed to get some alphablending of 2 images using sprites and fading one to another with direct3d. I would love to be able to do colorkeying on a color range, not on a specific color (which is an integer value with sprite.draw) Is this at all possible in direct3d? I couldn't for the life of me get the directdraw version to key anything but black and I am not sure that directdraw is the way to go nowadays.
Any help would be appreciated.


Leade 11-06-2009 08:13 AM

explain what you mean by color range.

do you mean dark red to light red, or any red to any blue?

the latter is not possible but i believe the earlier is, i just never done it.

Rockoon 11-06-2009 12:04 PM

if I remember correctly, most video cards did not support color keying of a range of values but instead only a single value.

Microsoft had been trying to get video card makers to support directdraw alpha blending as well, and that didn't become widely implemented either.

For Direct3D, alpha blending DID take off, so multi-color keying was left on the backburner as something not terribly important, since the image data can easily contain per-pixel alpha information which is even more versatile than color keying.

Single-color color keying is still widely supported because Direct Draw Overlays requires it, as most hardware accelerated video players absolutely require Direct Draw Overlays (even our "hardware mouse cursor" requires it)

All times are GMT -6. The time now is 10:31 PM.

Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2018, vBulletin Solutions, Inc.
Search Engine Optimisation provided by DragonByte SEO v2.0.15 (Lite) - vBulletin Mods & Addons Copyright © 2018 DragonByte Technologies Ltd.
All site content is protected by the Digital Millenium Act of 1998. Copyright©2001-2011 MAS Media Inc. and Extreme Visual Basic Forum. All rights reserved.
You may not copy or reproduce any portion of this site without written consent.