Re: Jpeg files and Win32Lib

new topic     » goto parent     » topic index » view thread      » older message » newer message

Have a look at my "TSEuImageEditor", which uses FreeImage library to load jpegs.

In file TSLibrary_DraWwnd.ew in procedure set_image() image is loaded like this:

    Main_freeimage_image = fiLoadImage (filename)
    Main_bitmap = fiCreateDIB (Main_freeimage_image)

Main_bitmap is HBITMAP

I think HBITMAP can be created also with cximage library.

Dave Probert wrote:
> 
> Hi All.  
> I've been looking for a simple way of loading Jpeg's into a Win32Lib Windows
> program.
>  
> So far I've looked at all the contributions under the search term 'jpg' and
> 'jpeg',
> but none of them really provides a sensible option.  ie they mainly are
> convertors
> into BMP's on disk - not really a great idea for something that might run from
> CD!!!
> 
> The CXImage DLL wrapper comes close to what my requirements are, but it does
> not produce
> anything I can use with Win32Lib directly (ie a DIB in the same format (and I
> thought
> DIB's were a Standard!!!!))
> 
> Has anyone (Mic!) enhanced that wrapper, or can anyone point me in the right
> direction
> as how to get a 'DIB' in the form {pixels, width, height, bpp} into a 'DIB'
> that can
> be displayed using CopyBlt, DrawBitmap, etc ????
> 
> I don't really want to be doing an execute of another executable (a la Al
> Getz's stuff),
> or using Tommy's Win32DIB (at the moment - though it's really, really good and
> should
> be incorporated into win32lib IMHO ;) ), but would prefer to have the
> simplicity of
> the cximage option - a single DLL, a simple wrapper and only a couple of
> calls.
> 
> I'm sure I can't be alone in this request - nowadays Jpeg's are standard, as
> are Png's,
> and BMP's are just cumbersome.  Let's get something that can work with these
> standards.
> 
> Thanks in advance.
>

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu