Adding only one layer #90
Answered
by
p-lr
RamaKrishnaBodavula
asked this question in
Q&A
|
I have only one layer / map image (png) to add, no seperated row and col images. Can we add it at the center instead of top left position. Or is there any other way for handling single layer map images. Thank you. |
Answered by
p-lr
Jun 10, 2023
Replies: 1 comment 4 replies
|
Although this library is almost usable for this usage, the fact that only square tiles are supported makes it not appropriate for now. val state: MapState by mutableStateOf(
MapState(1, 1920, 1920, tileSize = 1920) {
scale(1f)
scroll(0.5, 0.5)
}.apply {
addLayer(tileStreamProvider)
}
) |
4 replies
Answer selected by
RamaKrishnaBodavula
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Although this library is almost usable for this usage, the fact that only square tiles are supported makes it not appropriate for now.
However, if your single image has equal width and height, setting the tile size to the image size, and scrolling to the center should work.
In the example below, the single image is a square of 1920px width.