-
Notifications
You must be signed in to change notification settings - Fork 109
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug with auxiliary scale factor in ocad conversion #2080
Comments
Following Step 1 (creating a UTM-georeferenced project), I saw the auxiliary scale factor was 1, and the combined scale factor was not 1. Although this behavior is not what was reported for step 1, Mapper may not do what you expect for step 3, because OCAD does not provide for an auxiliary scale factor (as far as I can tell). There's no way for Mapper to save the auxiliary scale factor in an OCAD-format file. When Mapper reads an OCAD file, it assumes the combined scale factor is 1.0. When the combined scale factor is 1.0, then the auxiliary scale factor must be the reciprocal of the grid scale factor, which is a property of the projection. |
If I understand the cause of this issue, it occurs when the combined scale factor differs from 1.0. The background map and original map become misaligned in proportion to distance from the reference point. A workaround would be to use the Georeferencing dialog to adjust the combined scale factor to 1.0 before exporting in OCAD format. When it asks about stretching/shrinking the map content, say "Yes". |
Thank you for the answer and the explanation.
=> exactly
When importing, shouldn't OOM assume that the auxiliary scale factor is 1 instead of the combined scale factor. |
When I do as the manual describes, and load an OSM template right after creating the map, Mapper sets up the georeferencing with an auxiliary scale factor of 1.000000 for me. This makes sense because it creates a custom orthographic projection centered at the reference point. Are you doing something different? |
Yes, a georeferenced map developed in OCAD would have all relationships on the map drawn with a slightly different scale. Note that the purpose of Mapper's auxiliary scale factor is to compensate for small differences in scale due to altitude and to standard projections. Your .ocd file exported by Mapper has georeferencing offsets, but it has a scale that is superior to an OCAD map. If Mapper were “fixed” so that it exports .ocd files with better georeferencing, then it must either (1) stretch/reduce all the distances on the map, or (2) record the map's scale to be something like 1:10,005. |
That's my understanding, too, though I don't have OCAD to create a good example of the latter. The scale of a georeferenced .omap file is based on an ellipsoid model of Earth, and the projection from the grid to that model. The discrepancy between the two scales is the grid scale factor. When transforming between grid and map coordinates, Mapper applies both the grid scale factor (to compensate for distortion in the projection) and the auxiliary scale factor (an adjustment at the user's discretion). Those two factors taken together are the combined scale factor. OCAD uses the grid scale directly so it does not make these adjustments. In effect, OCAD's combined scale factor is 1.0. For this reason, Mapper is correct to set combined scale factor to 1 when importing a .ocd file. |
Yes (1) is the good solution for me. (even though it degrades accuracy but improve compatibility) If we consider that we do not apply an auxiliary scale factor (always =1), when we create a map in OOM the combined scale = 1(auxiliary scale factor)x Grind scale factor 0.99 (for example )=0.99 |
Yes I understand. |
I don't do anything different. |
Thanks for providing the .osm file! When I tried it on my development Linux system I still got an auxiliary scale factor of 1.000000. So I tried it on a Macintosh and saw the behavior you report. Then I recalled the discrepancy described in #2016. My Linux has PROJ 9.0, whereas the Mac release of Mapper 0.9.5 uses PROJ 7.1.1. The newer PROJ handles orthographic projections using a better ellipsoid, which is why on the Linux version I saw the auxiliary scale factor and grid scale factor equal to 1.000000. |
When importing a .ocd file ...
When Mapper imports the georeferenced objects, they will be positioned correctly, using the georeferencing of the imported file together with the georeferencing of Mapper's map. What use case do you have in mind for “later”? |
Now I believe this issue should be fixed by (1) stretching/reducing all the distances on the map. My reasoning is that the exported map has a simplified georeferencing. If in Mapper I created a new map with that simplified georeferencing, and imported the original map, Mapper would silently stretch/reduce the imported map. So it makes sense to do the same thing on export (without the complexity of requiring the user to intervene. or click OK). |
This is right on the mark. Mapper’s “map scale” is relative to the ellipsoid model (optionally adjusted by the auxiliary scale factor). OCAD’s “map scale” is relative to the grid. Having in mind that I would prepare a PR to address this issue, on further thought the simplest and most direct fix would be my “(2) record the map's scale to be something like 1:10,005”. It recognizes that Mapper and OCAD give different meanings to the "map scale", so there should not be an expectation that, for a particular georeferenced map, Mapper and OCAD would report the identical scale. Furthermore, (2) respects that the map is primarily a drawing on paper, and would not disrupt any paper distances. A reservation is that the file format does not support decimal fractions in the scale. As a consequence, rounding the map-to-grid scale for export will involve some loss of georeferencing accuracy. Assuming the reference point is within the map, I estimate that a typical map would have a georeferencing discrepancy of up to 0.2 meter. When importing an OCAD file to a new map, the inverse reasoning would apply, and again Mapper's “map scale” should not be identical to the value in the OCAD file. I have not looked into how Mapper currently addresses this subtlety on import. |
Steps to reproduce
1.Create a new project georerenced in UTM.
The grivation differt than 0, and auxiliary scale factor is not 1.
All it's right for the moment.
2.Convert this map to OCad format.
3.Re-open it in mapper.
Actual behaviour
Now the auxiliary scale factor as changed.
If we open this file as background map in the original project the map is mis placed.
Expected behaviour
The auxiliary scale factor should be constant when we convert à file in ocad format.
Configuration
Mapper Version: 9.4 / 9.5
Operating System:Windows
The text was updated successfully, but these errors were encountered: