Generate World Files for ECW?

Hi,

We are creating ECW files using Descartes for our clients. Unfortunately they are Autocad users and although autocad can attach a ecw raster it is not able to read the Geo information stored in it.

I have found there is a Lisp program that can be used to attach rasters including ecw's using an associated 'world file'

http://apps.exchange.autodesk.com/CIV3D/Detail/Index?id=appstore.exchange.autodesk.com%3AGeoRefImg%3Aen

Unfortunately in descartes there is no option to create 'Sister file' ( aka world file) for Raster types that already embed geo information ie ECW jpg2000 etc.

Can we have the option to generate a 'Sister file' for ecw's in a future release?

Mike

  • Hi Mike,

    Here is a workaround you can try to create sister files for your ECW files in the current versions of Raster Manager.

    1) Save As the ECW file to "Tag Image File Format". In the "Raster Save As Settings" dialog, set "Sister File" to "World File". If you don't want to do it manually for each raster you need to convert, you can also use Raster Manager's "Batch Convert". The TIF files should be created in the same folder as the ECW files.

    2) Once the TIF files and their associated TFW files are created, delete all the TIF files.

    3) Rename the extension of the TFW files to EWW. Again, if you don't want to do it manually, you can easily find apps online that will rename the files for you (e.g. ReNamer).

    I'll file a request on your behalf in our bug tracking system to ask for an option to generate a sister file for ECW files.

    Pascal


     This is a test

    Answer Verified By: hUbS 

  • Thanks Pascal.

    That's what I did. The problem is ECW's can be several Gb in size, converting to another format can take a long time.

    Mike

  • Hi Mike,

    If the ECW has no affinity or rotation it is quite simple to create the World File by hand.

    A world file has is made of 6 numbers, each on a different line, which can be deduced from the information in the Element Information dialog as followed

    Line 1 : Pixel size x

    Line 2 : 0

    Line 3 : 0

    Line 4 : -Pixel size y (note the minus sign)

    Line 5 : Origin x

    Line 6 : Origin y + Number of pixel y * Pixel size y

    So the world file for the data in the dialog below is :

    0.181126315789
    0
    0
    -0.181130229145
    247892.619282726110
    6270532.284671764800

    Note that if the rotation or affnity is not equal to 0 it is still possible to deduce the numbers, but the computations are more complicated.

    Also note that the number in a World File should be in meters.

    Thanks,

    Mathieu



  • Hi Mathieu,

    Looking into it a bit further, with no rotation Line 5 and 6 Correspond to the X and Y coordinate of the 'Center' of the 'Top Left' pixel so we have...

    WRL1 = PixelSize.X

    WRL2 = 0

    WRL3 = 0

    WRL4 = - PixelSize.Y

    WRL5 = Origin.X + PixelSize.X / 2

    WRL6 = Origin.Y + ('Number of Pixels.Y' * PixelSize.Y) - PixelSize.Y / 2

    Mike