Results 1 to 8 of 8

Thread: Stitching individual images together into a "projectable" whole?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Question Stitching individual images together into a "projectable" whole?

    The gist of what I'd like to do is to take a set of images of individual continents, each in its own (generally equirectangular oblique) projection, and stitch them together into a single file that could be reprojected at will. Each of the individual continent images is in a known projection and has many known lat / lon coordinates that could be used for referencing, so this seems like something that should be doable, but for the life of me I can't seem to find a way to get it to work. I've tried QGIS, but the georeferencer spits out nonsense when I try to reference my images. Blender might be another option, but I've never worked with that and so I'm not sure if it has the precision to do this. Any thoughts?

  2. #2
    Professional Artist Naima's Avatar
    Join Date
    Mar 2010
    Location
    Italy
    Posts
    1,584

    Default

    Use photoshop, compose in an equirectangular then use nasa g projector to change projection type.

  3. #3

    Default

    Hey Naima, I may not have explained my issues super well, so sorry about that. Doing as you suggest is fine and easy enough to do, but since even the initial conversion from "local" projection to equirectangular results in some loss / distortion of information, any projections from that compiled equirectangular just propogate and amplifies those artifacts. E.g. if I go local projection -> equirectangular -> local projection I don't end up with precisely the same image, which is kind of suboptimal. I'm looking for something that retains all of the information from the various local projections--a "master" file, if you will--from which I can generate any arbitrary other projection without accumulating artifacts. Does that make sense?

  4. #4
    Professional Artist Naima's Avatar
    Join Date
    Mar 2010
    Location
    Italy
    Posts
    1,584

    Default

    Depends what you need to do and scope, any starting projection can be your master file, for me is usually equirectangular for others might be dual paraboloid or else.
    The only thing that could give actual undistorted data is to operate directly on a sphere, use 3d elevation as master data and then when needed extract what you need.

  5. #5
    Administrator waldronate's Avatar
    Join Date
    Mar 2007
    Location
    The High Desert
    Posts
    3,607

    Default

    Quote Originally Posted by MrBragg View Post
    Hey Naima, I may not have explained my issues super well, so sorry about that. Doing as you suggest is fine and easy enough to do, but since even the initial conversion from "local" projection to equirectangular results in some loss / distortion of information, any projections from that compiled equirectangular just propogate and amplifies those artifacts. E.g. if I go local projection -> equirectangular -> local projection I don't end up with precisely the same image, which is kind of suboptimal. I'm looking for something that retains all of the information from the various local projections--a "master" file, if you will--from which I can generate any arbitrary other projection without accumulating artifacts. Does that make sense?
    I missed this the first time around, but the kind of damage/distortion that you're discussing is inevitable because you're resampling your grid of point-sampled data during every conversion. That means that one point in the input image samples to somewhere between zero and many points in the output image. If you save in a lossy image format such as JPEG, then things get even worse because those pixels are further mangled during the processing steps.
    The only way I know of to reduce total artifacts (and Naima alluded to in the next post) is to convert your explicit RGBA (or altitude for height fields) with implicit UV coordinate representation that you get in an image into an explicit UVX representation (X is RGBA or altitude in this case). There aren't a lot of tools available to work with lists of explicit points like this because an ideal representation would look a lot like a gaussian splat representation (the final image color is sampled from the UVX point cloud with a size determined by the local sparsity of the desired output area).
    One kind of representation that has tooling that _is_ widely available, though, is vector representations. Converting your input into a vector representation gives you something that QGIS can convert between projections without a huge loss in fidelity. There will inevitably be some losses due to numeric precision, but it is usually very much smaller than the losses due to raster grid conversions. If you are willing to keep your data in a UVX (or lat,lon,{data}) representation very early on and only go raster at the very last conversion for tools like Photoshop, then you'll get much better results than trying to keep everything raster all of the time.
    Going to a vector format requires that you convert your raster inputs to vector representations. There will be unavoidable losses from the vectorizer, but they are much better than they used to be. However, if you're working from a highly-detailed raster image (e.g. a lighted image of mountain ranges) then you may get lots and lots of tiny polygons that may translate to ugly slivers in different projections. The storage requirements for a vector representation may increase in that case (lots of tiny polygons) as well. The best case for a vector representation is things like continental outlines and relatively few altitude contours (or detail polygons).

  6. #6

    Default

    Editing images in equirectangular format gets harder with the cosine of the latitude.

    You could try something like this: Sketch out the map loosely in QGIS just showing the main features and layout, then produce templates from that for each region which you can fill in using Photoshop/GIMP, Wilbur or whatever raster tooling you like. Export as image at a consistent scale and DPI from QGIS making sure that the "worldfile" box is ticked; then you can edit the resulting file and import it back into QGIS, using the worldfile it originally generated, so you don't have to georeference it again.

    You can get an orthographic projection centred on any point on the globe by using the Globe Builder plugin; navigate to where you want, select the option to project on the centre of the map, and select "Add globe to a map". Be sure to set the scale back to your standard. Alternatively make a set of your own projections by copying something like Orthographic North Polar and changing the lat and lon numbers in the Proj 4 script to suit.

    Another thought is that if you use Mercator projection you lose the distortion as latitude increases in exchange for some unwanted scaling. So if you have a bunch of excerpts from a Mercator map, you can turn them into a common scale by resizing them by a factor of 1 / lambda. Gets fiddly at very high latitudes so at some point you go over to the orthographic polar.

  7. #7

    Default

    I don't know if it's exactly what you're looking for but part of my goal in coding this was to allow direct projection between any two arbitrary aspects (rotations of the globe relative to the projection). The reprojection is still lossy, as is necessarily the case for any approach to reprojecting raster images, but reducing the number of reprojection steps helps minimize that loss.

  8. #8

    Default

    I know this is probably too late now, but I just posted a thread with a tutorial to use photoshop to do exactly what you want to do. I'm just waiting for mod approval, but it is also available here: https://www.reddit.com/r/mapmaking/c...e_that_can_be/

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •