Pixel-width lines on image edges in Node-webkit export

Bugs will be moved here once resolved.

Post » Sat May 10, 2014 1:06 pm

Hate to say this, but would not using a spritesheet solve the problem as well?
Image ImageImage
B
168
S
50
G
164
Posts: 8,236
Reputation: 105,591

Post » Sat May 10, 2014 5:08 pm

@Ashley - Right, that makes sense. One more question, if you don't mind - I wonder if there's a way to generate mipmaps by isolating each animation frame to its own texture when creating the mipmaps (by either cropping the rest off or copying/pasting that singular animation frame to a new texture, then resizing it, then pasting it back to the spritesheet)? Then it wouldn't average pixels from adjacent images because there wouldn't be any.

Since the problem only happens on export, and sprite sheets only happen on export, having the textures isolated solves the issue, so I'm basically wondering if you can make that isolating behavior happen from a spritesheet at mipmap generation time.

Or, as newt said, perhaps giving us an option to turn sprite sheets off would be optimal for some users? Or would that essentially make no difference by resulting in the same amount of memory used as putting them all in power of 2 locations? I guess if that's the case then the only difference would be more file requests which is a disadvantage.
Moderator
B
94
S
33
G
33
Posts: 3,006
Reputation: 27,744

Post » Sat May 10, 2014 5:26 pm

Turning off spritesheets can increase the download size and could disable mipmaps unless they were still padded out to power-of-two sizes (since mipmaps are only supported on power-of-two textures), so it doesn't save memory or results in quality degradation equivalent to turning off mipmaps.

I think it is possible to custom-generate mipmaps which are correctly filtered according to the spritesheet, but doing that kind of logic in JS can considerably increase the startup time, since JS isn't always the best at heavy data processing. Right now we just use glGenerateMipmap which does it automatically in the driver.
Scirra Founder
B
387
S
230
G
88
Posts: 24,251
Reputation: 192,454

Post » Sat May 10, 2014 5:40 pm

Hmm... Maybe it could be an option to generate the mipmaps when exporting the game from C2? It would increase the download size (I've read mipmaps add 33%, don't know if that's correct or not) but improve startup times, and large games are quite common these days so 33% more image data might not matter for some users (for example, those making a downloadable exe, and the current fix increases download size too). My point is I think it's better to increase the download size rather than the memory use.

Also, does C2 generate mipmaps when previewing?
Moderator
B
94
S
33
G
33
Posts: 3,006
Reputation: 27,744

Previous

Return to Closed bugs

Who is online

Users browsing this forum: No registered users and 1 guest