Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Choppy Gradient on Splash Screen Windows Phone 7 Mango

Wondering if anyone knew a way to retain a good smooth gradient in a splash screen? I've tried both .jpg and loading the straight xaml as a logo control resource, and I've embedded in a viewbox. In the emulator it looks great! Though on the phone it still has that choppy 90's look to it and it's not doing my cool looking logo justice as a nifty splash screen. Any ideas?

like image 320
Chris W. Avatar asked Jan 18 '23 23:01

Chris W.


1 Answers

This is known as banding and occurs on the phones by default because they are set to 16bbp. You can manually change it to 32bpp by adjusting yor WMAppManifest.xml file to this:

<?xml version="1.0" encoding="utf-8"?>
<Deployment xmlns="http://schemas.microsoft.com/windowsphone/2009/deployment" AppPlatformVersion="7.1">
  <App xmlns="" BitsPerPixel="32" ...

(Source)

However, setting it like this to 32bpp can have a negative performance on your app. If you just need the gradient for your splash screen, you're better off dithering the image beforehand. Whilst this won't give you a perfect gradient, it will reduce the banding effect. Essentially, setting the 32bpp setting above enables a dithering-like algorithm to affect the render (which is one of the reasons there can be a performance hit). If you use Photoshop, you can use this dithering script but pretty much any art application will have a way of adding noise to the image.

like image 64
keyboardP Avatar answered Jan 30 '23 13:01

keyboardP