Search:
Submit Search


Virtual controls and pixel transparency

Using the CODM to create your own organ definitions, exchange CODM organ definitions, ...

Virtual controls and pixel transparency

Postby dfuchs » Fri Jan 20, 2017 8:44 am

I'm using Hauptwerk 4.2.1 Basic on a Windows 7 Home Edition operating system. While trying to build a virtual console with the CODM, I've noticed that I can't use semi-transparent pixels on controls that change their state. I was trying to mimic a shadow for a button by a semi-transparent grey area, but each time the button is pressed or released, a new picture is just put on top of the old one, so the shadows add up to an area of increasing opacity. I'd like to add that this behaviour also defeats anti-aliasing, where semi-transparent pixels are used to create smooth borders between opaque and transparent areas, so it seems that you can't really use transparency if a control has more than one state.

I know that in 'normal' consoles, images for controls include their part of the background, so there is no need for transparency. However, I'd like to use a kit of control images with text labels that should be independent of their background.

Has anyone noticed this problem before? Is it Hauptwerk's normal behaviour or is it maybe specific to my operating system and some graphics library which is used on my system? Is it the same on Mac?
There's nothing special about it. You only have to hit the right note at the right time, then the instrument will play all on its own. -- Bach
User avatar
dfuchs
Member
 
Posts: 14
Joined: Sun Dec 18, 2016 2:27 pm
Location: North-east Germany

Re: Virtual controls and pixel transparency

Postby mdyde » Fri Jan 20, 2017 8:52 am

Hello dfuchs,

Yes -- that's the intended behaviour; when a control changes state Hauptwerk only draws the image for the control itself -- it doesn't redraw all layers beneath for performance reasons. The sample set developer's guide covers that in depth (available to licensed Hauptwerks; send us an email if you'd like a copy).

Hence if you want to implement shadows then you need your images to include the relevant portion of the underlying layers.
Best regards,
Martin.

[Please use email or the Contact page if you need to contact us privately, rather than private forum messages.]

Image
User avatar
mdyde
Moderator
 
Posts: 10177
Joined: Fri Mar 14, 2003 2:19 pm
Location: UK

Re: Virtual controls and pixel transparency

Postby dfuchs » Fri Jan 20, 2017 9:06 am

Hello Martin,
Thank you for the ultra-fast reply. I'd like to put an enhancement request then. Could that behaviour be changed so that whenever a control is redrawn, all underlying layers would be refreshed before? Or maybe an option in the CODF to control this? I'm aware that real-time audio performance has top priority for Hauptwerk, but I also think that graphic libraries today are so fast that it shouldn't make much of a difference. Do you see a chance to implement this, and should I send an extra email for the enhancement request?
Best regards,
Daniel
There's nothing special about it. You only have to hit the right note at the right time, then the instrument will play all on its own. -- Bach
User avatar
dfuchs
Member
 
Posts: 14
Joined: Sun Dec 18, 2016 2:27 pm
Location: North-east Germany

Re: Virtual controls and pixel transparency

Postby mdyde » Fri Jan 20, 2017 9:19 am

Thanks, Daniel.

I've logged it as an enhancement request for future consideration. (We can't make any promises about whether, or specifically when, any given enhancement request will get implemented though.)
Best regards,
Martin.

[Please use email or the Contact page if you need to contact us privately, rather than private forum messages.]

Image
User avatar
mdyde
Moderator
 
Posts: 10177
Joined: Fri Mar 14, 2003 2:19 pm
Location: UK


Return to Custom Organ Design Module (CODM)

Who is online

Users browsing this forum: No registered users and 1 guest