Extending CPictureHolder for loading BMP, JPG, etc. Bridgeton NJ

This class extends the MFC CPictureHolder class to include better support for enhanced metafiles, access to picture handles, loading from files, and other capabilities.

Local Companies

M2Z Consulting Inc
(609) 750-0511
22 Van Wyck Dr
Princeton Junction, NJ
Absolute Roi Llc
(609) 748-4990
Absecon, NJ
Philip C King Consulting Inc
(201) 386-1088
519 Jefferson St
Hoboken, NJ
Gamming Labs Intl
(732) 942-3999
600 Airport Rd
Lakewood, NJ
Sergeant Consulting Associates Inc
(908) 273-9530
42 Maple St
Summit, NJ
Cigam Corporation
(908) 575-1811
681 Red Lion Way
Bridgewater, NJ
D & D Associates
(908) 730-8774
5 Cornish Pl
Annandale, NJ
H Kulkarni
(732) 438-1011
Dayton, NJ
Vigna Inc
(908) 281-7002
120 Stryker Ln
Hillsborough, NJ
Nazlo Associates Limited
(856) 228-8088
17 Roosevelt Ave
Blackwood, NJ

provided by: 
Originally published at Internet.com


Environment: VC6 (earlier probably ok too), Win2K/95/98

This class extends the MFC CPictureHolder class to include




Simply include the .h and .cpp into your project and use it as you would CPictureHolder.

You can also use this instead of the CBitmap class (but with code changes, of course).

And remember that CPictureHolder has a Render method to draw pictures, and it support transparency for GIF's etc.

I built this with various versions of VC6. I don't see why it wouldn't work on other recent versions.

NOTE 1: I would usually have made many of these member functions const. However, CPictureHolder doesn't use any consts, and so I would have to have done lots of (potentially unsafe) const casts in my code.

NOTE 2: Chensu says that OldLoadPicture/IPicture has problems with palettes. I haven't looked at his code yet, but if so, I will (with his permission) update this code to include whatever fixes he added to better support palettes

NOTE 3: I haven't included support for icons in here. It would be trivial to add so I'll leave it as an excercise for the reader :-) ...

Read article at Internet.com site

Featured Local Company

WorksForWeb Classifieds Ads Software for online business

0012026575939
1220 N. Market St Ste 806
Wilmington, DE

Related Local Events
Career & Technical Awards Luncheon
Dates: 5/13/2010 - 5/13/2010
Location: Heritage Ballrooms
Holmes, PA
View Details

Learn about Windows 7
Dates: 2/10/2010 - 2/10/2010
Location: The Delaware County Chamber of Commerce
Media, PA
View Details

Hot Java at the Watercooler
Dates: 12/23/2009 - 1/23/2010
Location: Odyssey Travel
Skippack, PA
View Details

Topics: 
Architecture & Design Languages & Tools Project Management Web Services
Database Microsoft & .NET Security Wireless
Java Open Source Techniques XML