viridis Posted January 29 Report Share Posted January 29 Hello and thanks for your development effort, In the past I have been strugling with heightmap import when mapmaking following palaxin's heightmap guide and written some posts in the forum regarding this: discussion on heightmap sources and technical data Novel method on preparing a heightmap from topographic and bathymetric images using ImageJ. The persisting problem I have experienced when importing a heighmap is that the image imported appear to be limited to 8-bit grayscale (or 24 bit RGB, but grayscale, which in practice is the same) whereas 0ad an its map editor allows 16-bit different heights. This fact is stated in the response of another post showing an import error. So, if the editor allows 16-bit height, why not allowing 16-bit grayscale images? I am convinced that mapmakers do not usually have enough technical background to deal with this and the suggestion of modifying the PMP map file by hand in a HEX editor is discouraging. So as I see it there would be two possible ways of improving the heightmap impor: Modify the code that import the image file allowing other options that can contains 16-bit images (such as TIFF or RAW) in order to edit the map in 16-bit already in your favourite editor. Write a plugin for your preferred image editor so that PMP files can be saved directly from image data and publish it. Open source community usually prefer GIMP, I use ImageJ, but any (free) image editor shall be picked. As I am not a programmer I cannot afford doing this by myself, however I encourage the development team to make a small effort in order to encourage mapmaking enthusiasts. Greetings. 2 Quote Link to comment Share on other sites More sharing options...
Stan` Posted January 30 Report Share Posted January 30 IIRC @vladislavbelov worked on it some time ago. 1 Quote Link to comment Share on other sites More sharing options...
Scallact Posted January 31 Report Share Posted January 31 Yes !!! We need that ! 16 bits import ability is the only missing link between elevation files and the Atlas. I have a GIMP plugin nearly ready, for the creation of elevation files, but I'm hesitant to publish since the import learning curve is too high. Your idea of a GIMP plugin for .pmp export is nice too, that would perfectly fill the gap. Before anyone asks, I don't think I would be able to write such a plugin with my current python level. :-) I might still try to look at it in the (not near) future if nothing moves on this front. Quote Link to comment Share on other sites More sharing options...
viridis Posted February 2 Author Report Share Posted February 2 (edited) Also asked at stackoverflow if easy to write a plugin or script for ImageJ. Should improve my own tutorial on this. Greetings. Edited February 3 by viridis Quote Link to comment Share on other sites More sharing options...
Scallact Posted February 2 Report Share Posted February 2 (edited) A temporary solution I found, useful if you are not confident with copy-pasting into a hex editor, is with a nice little command line utility: Swiss File Knife. It's multiplatform, and doesn't even require an installation. Just put the executable near your files and run it in a terminal. The useful command it provides is "partcopy", which allows to copy part of a binary file to another. An example command, to transfer elevation from a 385x385 uncompressed 16 bits greyscale .tif to a large .pmp : ./sfk partcopy [source_name].tif 8 296450 [map_name].pmp 16 -yes The number in the middle is the number of bytes. It must be adapted to the map's size: map size tif(px) bytes ----------------------------- normal 257 132098 medium 321 206082 large 385 296450 very large 449 403202 giant 513 526338 Edited February 2 by Scallact 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.