9 patch object appears blurry on export to mobile

Bugs will be moved here once resolved.

Post » Wed Sep 03, 2014 1:00 am

Problem Description
When you export a pixel based game using say - the retro template, if you ever use a 9 patch object, it becomes blurry featuring AA and other artefacting.
This is almost identical to a bug I reported a while back: https://www.scirra.com/forum/viewtopic.php?f=152&t=100468
That bug was fixed, but seemingly not for iOS export.

Images:
http://sean-noonan.com/development/dev_noonanrun/construct_ios_fukt_1.png
http://sean-noonan.com/development/dev_noonanrun/construct_ios_fukt_2.png
http://sean-noonan.com/development/dev_noonanrun/construct_ios_fukt_3.png

Attach a Capx
https://dl.dropboxusercontent.com/u/7282045/9patch_iOS_export.capx

Description of Capx
Just export the project to CocoonJS or Ejecta and run on an iOS device

Steps to Reproduce Bug
  • Export the project using CocoonJS
  • Deploy it to the CocoonJS app on an iOS device via iTunes
  • Run it!

Observed Result
9 Patch looks blurry

Expected Result
9 Patch has the same sharpness as the tiled and sprite objects

Affected Platforms
  • iOS export CocoonjS: (YES)
  • iOS export Ejecta: (YES)

Operating System and Service Pack
Windows 7 SP1 (problem witnessed on iPhone 5 and iPad 2)

Construct 2 Version ID
Release 178
B
45
S
9
G
2
Posts: 141
Reputation: 4,197

Post » Thu Sep 04, 2014 3:47 pm

Your screenshots are different to the .capx you have provided. Can you confirm that the problem occurs with the given .capx? It did not reproduce in iOS Safari or Android Chrome. Also the webgl/canvas2d setting may also affect it, does it happen with WebGL mode?

I would say this is likely to be Ejecta/CocoonJS issues, since if it works in all other platforms/browsers then it suggests our code is in fact correct.
Scirra Founder
B
395
S
232
G
88
Posts: 24,371
Reputation: 193,772

Post » Fri Sep 05, 2014 12:21 am

Image
Reproduced exporting to CocoonJS
B
45
S
9
G
2
Posts: 141
Reputation: 4,197

Post » Fri Sep 05, 2014 12:25 am

Oh and this is how it looks with WebGL disabled...
Image
B
45
S
9
G
2
Posts: 141
Reputation: 4,197

Post » Fri Sep 05, 2014 3:42 pm

Oh, I know what this is: the middle (tiling) patch is not power of two. Since you have 1px borders, the middle patch ends up 30x30, and WebGL can currently only tile power-of-two textures, so it will have to stretch the middle patch to 32x32 to tile it which affects the display quality.

There's not much we can do about this - hopefully WebGL 2 will fix it since it has non-power-of-two texture support.
Scirra Founder
B
395
S
232
G
88
Posts: 24,371
Reputation: 193,772

Post » Sat Sep 06, 2014 2:01 am

Even though it's fine using WebGL in a browser?

I assume when the new iOS is rolled out for everyone, this will be less of an issue?
B
45
S
9
G
2
Posts: 141
Reputation: 4,197


Return to Closed bugs

Who is online

Users browsing this forum: No registered users and 2 guests