Skip to main content
Question

How do I cascade several "readers" together before writing?

  • September 11, 2023
  • 3 replies
  • 10 views

billmcbride
Contributor
Forum|alt.badge.img+4

This is what I am trying to accomplish in FME:

A. Read a .jpg file, clip collars, add GCPs.

B. Feed that into a GeoTiff reader to convert to GeoTiff.

C. Feed the GeoTiff into a CADRG writer (requires GeoTiff for input).

 

I've done this with some (limited) success using "reader to GeoTiff writer",

then "GeoTiff reader to CADRG writer". (see my previous post on how the resultant GeoTiff raster was flipped horizontally)

 

As the GeoTiff is an intermediate format, how can I streamline this flow?

 

Thanks

bill

 

 

3 replies

redgeographics
Celebrity
Forum|alt.badge.img+49

You can use a FeatureWriter transformer to write a GeoTiff and then immediately a FeatureReader to read it back in and send it to the CADRG writer.

 

I haven't used CADRG myself but this does sound like an inefficient and non-FME way of doing it. From the documentation: "The CADRG writer accepts only rasters with a Red8 band, a Green8 band, and a Blue8 band.". This would indicate a JPG in RGB24 should work, have you tried a RasterInterpretationCoercer after processing the JPG so you can skip the whole GeoTiff detour?


billmcbride
Contributor
Forum|alt.badge.img+4
  • Author
  • Contributor
  • September 12, 2023
redgeographics wrote:

You can use a FeatureWriter transformer to write a GeoTiff and then immediately a FeatureReader to read it back in and send it to the CADRG writer.

 

I haven't used CADRG myself but this does sound like an inefficient and non-FME way of doing it. From the documentation: "The CADRG writer accepts only rasters with a Red8 band, a Green8 band, and a Blue8 band.". This would indicate a JPG in RGB24 should work, have you tried a RasterInterpretationCoercer after processing the JPG so you can skip the whole GeoTiff detour?

redgeographics, thank you very much for this recommendation. I'll be giving it a try later today. Using the CADRG format because we have a large database of CADRG imagery that meshes with the Falconview viewer. In the process of filling in some of the missing maps.

Thanks again,

bill


billmcbride
Contributor
Forum|alt.badge.img+4
  • Author
  • Contributor
  • September 27, 2023
redgeographics wrote:

You can use a FeatureWriter transformer to write a GeoTiff and then immediately a FeatureReader to read it back in and send it to the CADRG writer.

 

I haven't used CADRG myself but this does sound like an inefficient and non-FME way of doing it. From the documentation: "The CADRG writer accepts only rasters with a Red8 band, a Green8 band, and a Blue8 band.". This would indicate a JPG in RGB24 should work, have you tried a RasterInterpretationCoercer after processing the JPG so you can skip the whole GeoTiff detour?

Thanks, that saved a few steps, cleaner work flow, and worked well.

appreciated!

bill


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings