Raster with both World File and .Prj file not loading correctly

6917
9
06-01-2017 11:58 AM
ScottWagoner
New Contributor III

I recieve very large geotiff files.  In order to work with them, I use a software that converts them to a  jpeg for me.  When they are done converting they have both a world file and a .prj file.

But when I load them into ArcMap they have no spatial reference.  They only way they can be projected correctly is if I go in through the catalog and change the projection.  

Any Ideas why the .prj is not even showing up?

0 Kudos
9 Replies
DanPatterson_Retired
MVP Emeritus

by world file do you mean a *.tfw or *.jgw etc which are world files for tiff and jpeg respectively... prj are for shapefiles usually

CodyBenkelman
Esri Regular Contributor

Scott

Dan is correct - if you have a *.tfw and copy it, then rename with extension *.jgw it may simply work - but note the world file doesn't include projection information, so if you're working in different UTM zones, state plane, etc. you've still got potential for confusion.

I'm guessing that the data volume and processing time to create your JPGs is about the same as if you just used the GeoTIffs and built pyramids in external files.  Then you wouldn't lose the georeferencing, or degrade the quality of your full resolution data.  Is there a reason you're not doing this?

0 Kudos
ScottWagoner
New Contributor III

The reason we convert them, is to use the image in CAD and the computers we are using cannot handle such big files, so by changing to jpeg and messing with cell spacing a bit, we can lower the size of the file and make it more manageable.

0 Kudos
ScottWagoner
New Contributor III

It comes out with 3 files, the jpeg, a JGW file and a PRJ file

0 Kudos
DanPatterson_Retired
MVP Emeritus

the prj is probably just provided for convenience so that you would know what UTM zone the data are in assuming if it is projected data as Cody points out.  Defining the projection for the raster will work and you might try defining the coordinate system of the data frame before you add data to it.  If it is defined first, then it will be used, otherwise, the first file added to a data frame sets it coordinate system.

0 Kudos
ScottWagoner
New Contributor III

We will be defining the projection before loading it from here on out.  It will work, I was just confused that I had the files with coordinate systems and everything looks like it should work properly, but for some reason it doesn't.  

We don't do a huge number of conversions so it isn't that big of an issue.

Thank you for the help.

0 Kudos
ScottWagoner
New Contributor III

So if I may ask, what does give a jpg its projection?  The only thing that seemed to work was a .jpg.aux.xml  does this do it?

0 Kudos
DanPatterson_Retired
MVP Emeritus

check the reference link that shows the basic composition of the .jgw or tfw etc files.  It basically specifies the coordinates of a cell location, then the size of the cell in the x and y direction, then the number of rows and columns in the raster.  That is good... So you may know that the raster is projected into a UTM zone XX, but don't forget UTM coordinates are totally useless with the UTM Zone number... there are 120 locations on earth for each easting and northing (think about it...)  It is the UTM zone that specifies where it is on the globe.  The xml file (I haven't checked but you can) and the prj file will elaborate further as to what it is and in the case of UTM, give the zone number which is missing out of the 'world file'

0 Kudos
PeterBecker
Esri Regular Contributor

There is no standard convention for providing projection information to a JPEG. ArcGIS will use a JPW to provide an affine transform so as to position and scale the image, but no projection information is included. An associated AUX.XML can be used to include the projection information. It may not be used by some other applications. My recommendation would also be to not use JPEG, but use geoTIF instead. Open the original image in ArcGIS then use Export image but setting the format to TIF with JPEG_YCBCR compression. The size of the output can be decreased by changing the compression quality. (80% is gives typically about 6x from a non compressed natural color image). The quality value can be decreased to about 40, but then you will start seeing significant artifacts. You can also increase the pixel size which naturally also reduces the files size at the cost of quality.

The other better solution is to server the imagery as an image services and turn on WMS. Many CAD applications including AutoCAD and Microstation can consume these WMS services so maintaining the original image quality. 

0 Kudos