Real Software Forums
http://forums.realsoftware.com/

My Retina Code Messes With My Windows Builds
http://forums.realsoftware.com/viewtopic.php?f=1&t=47780
Page 1 of 1

Author:  StephenD [ Fri May 03, 2013 3:15 pm ]
Post subject:  My Retina Code Messes With My Windows Builds

So, I added support for retina on the Macbook Pro. Text looks great.

I made icons double size and draw them at half size on canvas. This makes them look sharp on retina and fine on normal Macs with no conditional drawing needed. I use code like this in the Canvas.paint event:
g.DrawPicture currentPic, 0, 0, currentPic.Width *.5, currentPic.Height *.5, 0, 0, currentpic.Width, currentPic.Height


However, when running on Windows, my half size icons have unacceptable artifacts from the halving. I assume the Windows graphics renderer is not as spiffy.

Do I need to create 2 versions of all my icons or is there some trick I've missed?

Author:  charonn0 [ Fri May 03, 2013 5:36 pm ]
Post subject:  Re: My Retina Code Messes With My Windows Builds

Works/looks just fine for me on Windows 7. Maybe set App.UseGDIPlus to True.

Author:  StephenD [ Sat May 04, 2013 3:52 pm ]
Post subject:  Re: My Retina Code Messes With My Windows Builds

Thanks. Alas, same dodgy result with App.UseGDIPlus

Same for me for Win 7 and Win XP.

Making the image even pixel dimensions helps but some images, like those with repeating straight lines, just don't scale.

Author:  Bob Keeney [ Sat May 04, 2013 4:09 pm ]
Post subject:  Re: My Retina Code Messes With My Windows Builds

StephenD wrote:
Do I need to create 2 versions of all my icons or is there some trick I've missed?


I believe this will be your best best. I believe that even Apple recommends having 2 sizes of images, 1 for regular and 1 for Retina Display. Scaling doesn't work in all cases.

Author:  StephenD [ Fri May 24, 2013 8:38 am ]
Post subject:  Re: My Retina Code Messes With My Windows Builds

Thanks Bob.

Anyone have suggestions on the best way to manage images?

Author:  tomis [ Fri May 24, 2013 11:40 pm ]
Post subject:  Re: My Retina Code Messes With My Windows Builds

Are these images masked? If so, do non-masked images scale without aliasing?

I'm experiencing unacceptable aliasing when scaling masked images under Mac OS X Cocoa builds. However, if I pre-composite to a non-masked picture and scale that instead, I don't have this issue.


------
Edit: It seems Real Studio isn't setting the interpolation correctly on Cocoa. The solution is discussed at viewtopic.php?f=7&t=47968

Author:  StephenD [ Tue May 28, 2013 6:36 am ]
Post subject:  Re: My Retina Code Messes With My Windows Builds

They're not masked. I'd hate to have to go back to masking my images.

Page 1 of 1 All times are UTC - 5 hours
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/