Big problem with tilemap and webGL off, CocoonJS

Discussion and feedback on Construct 2

Post » Wed Mar 05, 2014 10:33 pm

EDIT: I ""fix"" the problem with high-DPI display= yes, but just on the iphone, on the computer I have the same problem

Hi everybody, I have a very big problem about this...

I made some tilemap in 64x64 and it was perfect after I disable the webGL.

Why I would to disable the webGL? because with cocoonJS the frame will be amazing...

I was made 6 or 7 object with a sine movement (for testing), with webGL, the frame was 42/38!![/b] but, when I disable the webGL the fps turn on 62!!! without slowing down or lag!!

I don't need to use webGL because I don't use effect for my project...

Now, where is the problem? [b]the tilemap... every tile has a tiny outline and I don't undertand why...


someone know how I can fix it? it's very tiny trasparent outline...

and another question is, I read in the manual, if you use webGL, the performance incrase like twice...now, why in cocoonJS is different? with the webGL the performance is ok, but if I disable it will be perfect??

thank you very much!!
B
21
S
9
Posts: 298
Reputation: 2,967

Post » Thu Mar 06, 2014 10:25 am

"every tile has a tiny outline and I don't undertand why..."

in the past I was trying to use TiledBackground on CocoonJS and it always have such outline
B
18
S
7
G
1
Posts: 783
Reputation: 4,247

Post » Thu Mar 06, 2014 11:04 am

found-solution-for-seams_t93983?&hilit=seams
it has to do with sub pixel rendering vs integer gpu rendering.
B
15
S
6
G
4
Posts: 277
Reputation: 3,948

Post » Thu Mar 06, 2014 1:10 pm

@Roccino

so only way to use Scale Outer + Linear Sampling and TileMap without seams
is to make 1px invisible border around every tile?
B
18
S
7
G
1
Posts: 783
Reputation: 4,247

Post » Thu Mar 06, 2014 2:35 pm

Roccinio wrote:https://www.scirra.com/forum/found-solution-for-seams_t93983?&hilit=seams
it has to do with sub pixel rendering vs integer gpu rendering.


so, what I can do it? I read the topic but I don't really understand how fix the problem, I tried a lot of combination (this night I will try another things... now I don't have my project with me)

if I disable the webGL I can see a seams, but with the webGL the performance will be fewer like 20 fps...

why in CocoonJS the webGL make this problem? I should contact ludei?

It's very important the fps, because when the fps is 40/35 you can see a lot of lag...

szymek wrote:@Roccino

so only way to use Scale Outer + Linear Sampling and TileMap without seams
is to make 1px invisible border around every tile?



I tried a lot of combination... tonight I will try again
B
21
S
9
Posts: 298
Reputation: 2,967

Post » Thu Mar 06, 2014 2:39 pm

if you want tilemaps without seams you must select sampling to "point" and maybe pixel rounding to "on"
but you will lose scrolling quality and some png's will look a lot worse than the one you exported from lets say photoshop.
if you create 1px invisible border around every tile how will you tile them? ;)
the only other way to not have seams without using the above at least to my knowledge is to use your tilemaps as sprites with animation frames. read the tutorial from ashley about "basic platformer"
B
15
S
6
G
4
Posts: 277
Reputation: 3,948

Post » Thu Mar 06, 2014 2:40 pm

it has nothing to do with cocoonjs. it has to do the way gpu renders pixels.i gave you above the solution.you pick what works best for you
EDIT i am not sure if cocconjs supports any of the above so go with solution no 2 just to be sure
B
15
S
6
G
4
Posts: 277
Reputation: 3,948

Post » Thu Mar 06, 2014 2:46 pm

Roccinio wrote:if you want tilemaps without seams you must select sampling to "point" and maybe pixel rounding to "on"
but you will lose scrolling quality and some png's will look a lot worse than the one you exported from lets say photoshop.
if you create 1px invisible border around every tile how will you tile them? ;)
the only other way to not have seams without using the above at least to my knowledge is to use your tilemaps as sprites with animation frames. read the tutorial from ashley about "basic platformer"


thank you very much for the reply, but I would prefer to use the tilemap... it's perfect to load with JSON file and implement in the future new level from internet.... with the sprite I need to "redesign" all of my game... this is my last point if i don't solve the problem :D

I don't remember if I try this combination, if a lose the quality of png I don't care if my game run 60fps on iphone...

the must of people don't care if the quality of the image is perfect, you can see a lot of application with a lot of download and the quality of the graphics are not very good...

I don't understand that, If I make every tile with a trasparent border what happen?

thank you very much again
B
21
S
9
Posts: 298
Reputation: 2,967

Post » Thu Mar 06, 2014 3:01 pm

@Roccino

"the fix: extrude 1px border from the texture outwards "

ok, maybe I don't get the whole idea :)

anyway I think that if there are seams on tiles with linear sampling, then there is - in fact - no real use for many people who would like to use tiles
B
18
S
7
G
1
Posts: 783
Reputation: 4,247

Post » Thu Mar 06, 2014 6:09 pm

@szymek
glad i could help!
i had to learn all these the hard way.wish i had someone to tell me earlier.
@ashley says that that's the way it is but i cant believe this because it renders the whole tilemap thing useless for many situations.
so if you want to help out,
bug him until he figures out a way! :)
B
15
S
6
G
4
Posts: 277
Reputation: 3,948

Next

Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 10 guests