FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Want PNG Support?

 
Post new topic   Reply to topic     Forum Index -> DFL
View previous topic :: View next topic  
Author Message
Chris Miller



Joined: 27 Mar 2004
Posts: 514
Location: The Internet

PostPosted: Thu Mar 27, 2008 6:43 pm    Post subject: Want PNG Support? Reply with quote

Is PNG support pretty important at this point?

I can get PNG support with GDI+ and a different Picture implementation.

Things to consider:

GDI+ won't work on Windows 95, and doesn't come with 98, Me or 2000.

For better compatibility, it might be better to have a separate Picture class for GDI+, and keep the current one as well; but also have a compile-time switch to turn the regular Picture into the GDI+ one if desired.

If going with a separate class, what will it be named?

Or, just load GDI+ in Picture if available, falling back to the current one if no GDI+. This has down sides: GDI+ does things better, so different users will get different results; and it could bloat Picture a bit.

Could be a combination of all the above.
Back to top
View user's profile Send private message
Al



Joined: 10 Mar 2008
Posts: 9

PostPosted: Fri Mar 28, 2008 7:43 am    Post subject: Reply with quote

I would describe PNG support as "somewhat important" for me ATM.
Meaning, I can survive without it, but having PNG supported would be nice (mainly for it's alpha channel capabilities).

As for the way to do it.. It would be nice to have a single class and auto-everything, I guess - having to check if the OS is GDI+ capable or not each and every time you need to create a Picture/PicturePlus (a GDI+ aware Picture Wink ) would be bothersome, even if we're talking about checking a single bool flag here.

So, how about adding GDI+ support to the Picture class, but providing it with "bool dontUseGdiPlus" property, which would make the Picture rely on GDI only? (or something like this)

I don't think the bloat is going to be that significant, is it?
Back to top
View user's profile Send private message
Chris Miller



Joined: 27 Mar 2004
Posts: 514
Location: The Internet

PostPosted: Fri Mar 28, 2008 9:45 pm    Post subject: Reply with quote

You have good points; I might do it that way.
Back to top
View user's profile Send private message
HateWork



Joined: 20 Oct 2007
Posts: 13

PostPosted: Tue Apr 01, 2008 8:28 pm    Post subject: Reply with quote

I think there's already a D port for png, or at least an import file for the dll but in this case all dfl programmers must include the png dll with their program.

I hope you get the idea.
Back to top
View user's profile Send private message
Al



Joined: 10 Mar 2008
Posts: 9

PostPosted: Wed Apr 02, 2008 10:53 am    Post subject: Reply with quote

Well.. sure, you CAN use whatever lib you've got for png.
You can even write png-loading/drawing code yourself! Wink

But the question was: does anyone need built-in png support in DFL (using Picture/Picture-based class), AFAIK
Back to top
View user's profile Send private message
HateWork



Joined: 20 Oct 2007
Posts: 13

PostPosted: Mon May 05, 2008 5:40 pm    Post subject: Reply with quote

PNG support is more than important at this point.

Quote:
But the question was: does anyone need built-in png support in DFL (using Picture/Picture-based class), AFAIK


I do! Create a poll please!
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> DFL All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group