|
-
Jan 6th, 2022, 05:40 AM
#4
Re: Cairo Equivalents Setpixel(Yes & Easy), Getpixel(???) [L-Plate Learner Edition]
So, what you're saying is - that your 1000^2 Maps are just smaller representations of the
"fully rendered, tile-based views" (one Pixel in them, representing "a tile with a certain type").
In that case, since your mappings remain in the "visual realm" (are just "zoomed-out" Layers of the real thing),
editing such kind of "map-infos" in Cairo-Surfaces (or in PhotoShop or "Paint") does indeed make sense.
But for storing such "visually prepared" map-defs, I'd choose an SQLite-Database, for several "good reasons".
(an existing - e.g. PhotoShopped 1000x1000 overview-layer-map can be imported into a DB-Table in a small routine - within 1 sec).
I could explain these reasons in detail (in case you want to go there)...
If you don't want to go "all DB" (having all your image-resources, all your Map-Layer-definitions in a single file),
that's also an option (but a far less "elegant" one).
To mention at least the main-reason, why a DB-based approach makes sense...:
It would allow you, to have a "size-wise unlimited world-map" - and it would allow
"seamless scrolling and zooming" on that huge world-map via simple SQL-queries
(queries which would allow you, to give the true target-rectangle of your current tile-view,
and produce a result-recordset which contains all Layer-Type-infos for all Tile-Types of that View-Rect in about 1msec).
Olaf
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|