0

I have a large image 6000 x 3044 I need to add it into my silverlight app. Only at runtime the image looks as you see below:

enter image description here

Why it doesn't look as the design on the left? Note that the image control I'm using has the same size of the image file that is 6000 x 3044.

Hamzeh Soboh
  • 7,572
  • 5
  • 43
  • 54
  • It's a limitation in WP7 see here: [1]: http://stackoverflow.com/questions/3890520/bitmapimage-size-restrictions-in-silverlight [2]: http://stackoverflow.com/questions/8902581/some-jpegs-not-displaying-correctly-size-limitation – Hamzeh Soboh Apr 05 '13 at 18:22

1 Answers1

0

The result is called a Moiré pattern: http://en.wikipedia.org/wiki/Moire . As long as you scale the image, it is unavoidable unless a) the scaling factor is a whole number or b) you remove the hatching from the original pattern.

Boluc Papuccuoglu
  • 2,318
  • 1
  • 14
  • 24
  • Thanks for your answer. But I'm not scaling anything. The image I'm using is large but not scaled. Is there any solution? – Hamzeh Soboh Apr 04 '13 at 19:44
  • The scaling is being done automatically it seems. You say that the image control and the file are the same size, but the image control can have a non-zero margin or padding that would result in the scaling. You can try to set the stretch property of the image to None – Boluc Papuccuoglu Apr 04 '13 at 19:50
  • Nice way to think, but it didn't work. An important point is that why in the design there's no problem. Only when deploying the app on the emulator, the image distortion appears. – Hamzeh Soboh Apr 04 '13 at 19:59
  • Does the distortion also occur when you deploy to a physical device? – Boluc Papuccuoglu Apr 04 '13 at 20:01
  • Unfortunately, I don't have a physical device to test my apps on :( – Hamzeh Soboh Apr 04 '13 at 20:04