It will be useful to have uniform parameter with tile index (x,y) and layer index in fragment and vertex shaders. A vec4 can hold all informations!
This would however break the batching which would give you one draw call per tile.
This is not an approach we would recommend.
For the tile index, I suggest you do some arithmetic on the position
to find out what tile index it is. I.e. divide by tile size.
Without layer index I’ll have to split each tilemap into 2 different tilemaps, but I’ve already designed 30 levels …
The file format is text based, so you can read a file, and output another.
You could create a script that creates these extra tilemaps if you wish.