edgar.soldin wrote: > On 21.09.2011 14:11, Rahkonen Jukka wrote: >> Hi, >> >> Here is a nice 18K photo: >> http://www.openjpeg.org/samples/Cevennes2.jp2
> seems like this one is missing xml metadata, which the ecw driver seems to > insist on. the error message seems > to come directly from the ecw binary. > maybe kosmo patched theirs? Yes, ESRI world files are usually used just for georeferencing plain image files. World files do not tell the coordinate system that is used so using them is actually not very good. The ER Mapper native way for georeferencing images was to use external .ers file which had more metadata. Images with world files were not opened dierectly by ER Mapper but they were imported through a wizard which created an .ers file Georeferencing .ecw images is done with internal headers included in the file itself. Therefore it is not surprising that ECW SDK based drivers do not read .eww world files for .ecw images. Anologously, because the same driver is used for reading JPEG2000 images, it is no wonder that .j2w world files are not utilised. I would guess that Kosmo is patched somehow. >> GvSIG does not open it. It generates 37493 characters long error message >> instead and the error window is (perhaps) impossible to close withour >> killing gvSIG. Kosmo does open this image as well as my non-georeferenced >> aerial images. However, Kosmo is placing the image into coordinates (0,0) >> even is they have corresponding world file. >> ER Viewer 7.0 does not get georeferencing from world files either so maybe >> we will out of luck. But Kosmo is close to success. All that is missing is >> to slide and scale the image according to .j2w file values. > i really don't want to replace the current implementation with kosmo code > now. it works in general, and for cornercases like these i could imagine a > proper convert to tiff or something else lossless does the trick. I think there is not need to replace your code. It works pretty well and what is missing is good advice for preparing the .ecw and .jp2 images in such a way that they can be used. For .ecw images there is a EVW Header Editor tool which can be used for adding and repairing the georeferencing metadata. It is still available from ERDAS for free, even it is compulsory to make an ERDAS account first. I do not yet know any tool which could be used for adding and editing the GEOJP2 tags inside JPEG2000 without rewriting/uncompressing/re-compressing the image data itself but for sure such useful tools exist. I will tell once I have found some that is free enough for OpenJUMP users. >> I have used JPEG2000 world files in a standard way. I have copied the >> original .tfw file into .j2w and placed it into the same directory than .jp2 >> image. Gdal is recognising .j2w file as well as some other programs. Some >> programs don't read the world file. > can have a look at world file jp2 support. but you mentioned in another mail > (layermanager) you can't add jp2 files. could you elaborate where and how you > are not able to load jp2 files? I can open .jp2 images with Open-File menu. I was meaning that the Image Layer Manager (test)... system that can be accessed through Right click meny from the layer list. See the image at http://latuviitta.org/documents/OJ_Image_Layer_Manager.png It should show I have added totally 8 .ecw images into one OJ layer. The manager shows the list of the included images and the map shows the outlines of the image tiles. And the Open dialog that open after using the Add button shows that this nice feature cannot be used with .jp2 images because they do not appear on the list of all supported formats. -Jukka- th anks ede > > -Jukka- > > >> -----Alkuperäinen viesti----- >> Lähettäjä: edgar.sol...@web.de [mailto:edgar.sol...@web.de] >> Lähetetty: 21. syyskuuta 2011 14:37 >> Vastaanottaja: OpenJump develop and use >> Aihe: Re: [JPP-Devel] OpenJUMP with JPEG2000 test results >> >> does gvsig 1.11 open plain jp2 for you? >> do you have a small plain jp2 to play with? >> >> ede >> >> On 21.09.2011 11:57, Rahkonen Jukka wrote: >>> Hi, >>> >>> I had a test with OpenJUMP-snapshot20110920-r2420-bin.zip >> on Windows Vista 32-bit and Windows XP Pro 32-bit and jre 1.6.0_27. >>> >>> Test 1. >>> GeoJP2 (.jp2) images created with Kakadu kdu_compress. >> Original images have been geotiffs and in this case >> kdu_compress is creating a GeoJP2 file with included >> georeferencing info. >>> Result: 1-channel (black and white) and 3-channel images >> (RGB) are shown fine. >>> >>> Test 2. >>> JPEG2000 images created with ER Mapper Image Compressor 7.2 >> from georeferenced images (tiff files with tfw). >>> Result: OK >>> >>> Test 3. >>> Non-georeferenced .jp2 files created with Kakadu and ER >> Mapper Image Compressor. >>> Result: OpenJUMP seems to open the images (no error >> messager) but it does not show them. Having a world file does >> not change the situation. I tried worldfiles with the .j2w >> ectensions as well as .tfw with the same result - image is not shown. >>> >>> Test 4. >>> I tried to convert on 3-channel 12000x12000 pixel image >> into .jp2 with Geojasper (tif2jp2.bat). Procedure took very >> long and ended to program termination with some system error >> message "memory can not be read". It may be some hardware >> problem but first try with Geojasper was not very inspirating. >>> >>> Test 5. >>> >>> FWTools 2.4.7 from http://fwtools.maptools.org comes with >> JP2ECW driver that can write out JPEG2000 files. >>> I converted a test image (tiff+tfw) into .jp2 as >>> gdal_translate -of JP2ECW test.tif JP2ECW_test.jp2 >>> Result: OpenJUMP opens and shows the image with georeferencing. >>> >>> Note: This FWTools version writes also ECW and it is so old >> that the ECW license at that time allowed converting source >> images which are less than 500 GB in size into ECW. I am >> remenbering that ER Mapper had a free Image Compressor 2.x >> with the same size limit. I would recommend downloading >> FWTools 2.4.7 as long as it is available and keep it in a >> safe place for future needs. >>> >>> Test 6. >>> OJ opens multi-channel .jp2 images (7 and 8 channel Landsat >> scenes) created with Kakadu. Georeferencing is OK but the >> result is not usable because it is not possible to select >> bands for viewing. One channel for grayscale or three >> channels for RGB would make sense but not a grayscale >> presentation of all the 7 channels in a pile. >>> >>> Test 7. >>> Simple .jpx and .jpf files can be used but not the more >> exotic variants. I believe that these must also contain the >> internal georeferencing info but I am not sure. It is also a >> long time since I have played with JPEG2000 and I do not even >> remember for what these variants are usable. >>> >>> Test 8. >>> Unwrapped JPEG2000 code streams (.j2c, .j2k) cannot be >> viewed. Probably because they are naturally lacking the >> georeferencing info. >>> >>> Conclusion: >>> OpenJUMP can show typical JP2 compatible 1-channel and >> 3-channel JPEG2000 images if they include the georeferencing >> information internally (GeoJP2). Such images can be created >> from geotiffs with Kakadu kdu_compress utility which is free >> for personal use. Old versions of gdal_translate can be used >> for creating OpenJUMP compatible .jp2 images with JP2ECW >> driver up to 500 GB input file size. >>> Unfortunately OpenJUMP does not show at all images without >> georeferencing or which have only .j2w world file for >> georeferencing. And unfortunately the free Geojasper tool >> failed in my test. >>> >>> -Jukka Rahkonen- >>> >>> >> -------------------------------------------------------------- >> ---------------- >>> All the data continuously generated in your IT >> infrastructure contains a >>> definitive record of customers, application performance, security >>> threats, fraudulent activity and more. Splunk takes this >> data and makes >>> sense of it. Business sense. IT sense. Common sense. >>> http://p.sf.net/sfu/splunk-d2dcopy1 >>> _______________________________________________ >>> Jump-pilot-devel mailing list >>> Jump-pilot-devel@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel >> >> -------------------------------------------------------------- >> ---------------- >> All the data continuously generated in your IT infrastructure >> contains a >> definitive record of customers, application performance, security >> threats, fraudulent activity and more. Splunk takes this data >> and makes >> sense of it. Business sense. IT sense. Common sense. >> http://p.sf.net/sfu/splunk-d2dcopy1 >> _______________________________________________ >> Jump-pilot-devel mailing list >> Jump-pilot-devel@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel >> > ------------------------------------------------------------------------------ > All the data continuously generated in your IT infrastructure contains a > definitive record of customers, application performance, security > threats, fraudulent activity and more. Splunk takes this data and makes > sense of it. Business sense. IT sense. Common sense. > http://p.sf.net/sfu/splunk-d2dcopy1 > _______________________________________________ > Jump-pilot-devel mailing list > Jump-pilot-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel ------------------------------------------------------------------------------ All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2dcopy2 _______________________________________________ Jump-pilot-devel mailing list Jump-pilot-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel ------------------------------------------------------------------------------ All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2dcopy2 _______________________________________________ Jump-pilot-devel mailing list Jump-pilot-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel