comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Reading 32-bit BMP (with an alpha channel) in IDL
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Reading 32-bit BMP (with an alpha channel) in IDL [message #70022] Tue, 09 March 2010 14:58
penteado is currently offline  penteado
Messages: 866
Registered: February 2018
Senior Member
Administrator
On Mar 9, 7:09 pm, Brian Daniel <Daniels...@yahoo.com> wrote:
> I appreciate the ability to display alpha banded images.  TVImage is
> extremely useful.  However, I was trying to read BMPs with alpha
> channels, and read_bmp.pro just doesn't cut it.  I added a case for a
> 32 bit/pixel situation and added a dimension to the readu statement.
> Its a small fix, but why didn't ITTVis put this in read_bmp.pro?
> Alpha channel images are a standard format!

Have you tried iopen? I do not know if it uses an independent
implementation, or just passes that work on to read_bmp.
Re: Reading 32-bit BMP (with an alpha channel) in IDL [message #70023 is a reply to message #70022] Tue, 09 March 2010 14:09 Go to previous message
Brian Daniel is currently offline  Brian Daniel
Messages: 80
Registered: July 2009
Member
On Mar 9, 2:28 pm, David Fanning <n...@dfanning.com> wrote:
> Brian Daniel writes:
>> I have a set of BMP images I need to read in.  They have 4 channels,
>> red, green, blue and alpha.  Every commercial image viewer I have can
>> open them, including matlab.  Now, I could go to the trouble to
>> convert them to 24-bit or another image format, but why should I
>> change?  IDL should be able to read this standard input.  Read_bmp.pro
>> explicitly states that it can only read 24-bit.  Is there something
>> built-in I'm not seeing?  Is there a coyote function that already does
>> it?
>
> Here is an article that explains what is happening:
>
>   http://www.dfanning.com/ip_tips/transparentpng.html
>
> TVImage will display these images correctly. :-)
>
> Cheers,
>
> David
>
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming:http://www.dfanning.com/
> Sepore ma de ni thue. ("Perhaps thos speakest truth.")

I appreciate the ability to display alpha banded images. TVImage is
extremely useful. However, I was trying to read BMPs with alpha
channels, and read_bmp.pro just doesn't cut it. I added a case for a
32 bit/pixel situation and added a dimension to the readu statement.
Its a small fix, but why didn't ITTVis put this in read_bmp.pro?
Alpha channel images are a standard format!
Re: Reading 32-bit BMP (with an alpha channel) in IDL [message #70026 is a reply to message #70023] Tue, 09 March 2010 11:28 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Brian Daniel writes:

> I have a set of BMP images I need to read in. They have 4 channels,
> red, green, blue and alpha. Every commercial image viewer I have can
> open them, including matlab. Now, I could go to the trouble to
> convert them to 24-bit or another image format, but why should I
> change? IDL should be able to read this standard input. Read_bmp.pro
> explicitly states that it can only read 24-bit. Is there something
> built-in I'm not seeing? Is there a coyote function that already does
> it?

Here is an article that explains what is happening:

http://www.dfanning.com/ip_tips/transparentpng.html

TVImage will display these images correctly. :-)

Cheers,

David


--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thue. ("Perhaps thos speakest truth.")
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: Dynamic arrays in structs: re-allocation problem
Next Topic: Creating a widget for probability table

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 04:44:31 PDT 2025

Total time taken to generate the page: 1.12101 seconds