tilemap icon indicating copy to clipboard operation
tilemap copied to clipboard

Why when tileset's size > 1024 , the `texPreChild` have to be `1`

Open finscn opened this issue 8 years ago • 6 comments

when the image of tileset is bigger then 1024*1024 , the texPreChild have to be 1, otherwise there is a error

[.Offscreen-For-WebGL-0x7fd913871800]GL ERROR :GL_INVALID_VALUE : glTexSubImage2D: bad dimensions.

And the result of rendering will be mistake.

finscn avatar Aug 23 '17 14:08 finscn

Tilesets more than 1024 are not supported. That code was mode for RMMV in a hurry and there's no middle solution that works both with large and small tilesets, wait for 2.0 that I'm working on now.

You can use it in your fork for now :)

ivanpopelyshev avatar Aug 23 '17 14:08 ivanpopelyshev

~~I found there some hard-code1024 in source. they are the reason ? I try to change them from 1024 to 2048 , but no effect and take more mistakes....~~

finscn avatar Aug 23 '17 14:08 finscn

Exactly.

ivanpopelyshev avatar Aug 23 '17 14:08 ivanpopelyshev

@ivanpopelyshev , where can I find 2.0 ?

finscn avatar Aug 23 '17 14:08 finscn

You can find WIP plugin for atlas here: https://github.com/gameofbombs/pixi-super-atlas

I'm working on it right now.

ivanpopelyshev avatar Aug 23 '17 14:08 ivanpopelyshev

If we just remove those renderTextures, RMMV will stop working and that'll be very bad.

The only solution is to make runtime atlas that can combine BaseTextures with limits only on number of texture slots and the size of GL texture.

ivanpopelyshev avatar Aug 23 '17 14:08 ivanpopelyshev