Skip to main content
Question

Set extent of raster to PDF writer

  • February 22, 2018
  • 9 replies
  • 37 views

apence231
Contributor
Forum|alt.badge.img+7

I'm slowly getting this PDF to work and have made some progress, now getting stuck in another spot. Right now the process is I clip a raster and a points shapefile by the same polygon > rotate both > and export out to a PDF. I've figured out how to rotate and align the points all neatly, but I want the raster image to fill the extent I want. Examples:

The extent I want (made from ArcMap) on top and the extent that FME outputs:

9 replies

erik_jan
Contributor
Forum|alt.badge.img+17
  • Contributor
  • February 22, 2018

I am not an expert on this, but could the PDFPageFormatter transformer help?


debbiatsafe
Safer
Forum|alt.badge.img+20
  • Safer
  • February 22, 2018

Hi @apence23

Like erik_jan's comment, I would recommend the PDFPageFormatter.

You can place and resize your raster object to the extent that you want within the PDFPageFormatter.

Please ensure Maintain Aspect Ratio is set to 'Yes'. To check, right-click on blue part and select Properties from the drop-down menu.

Hope this helps,

Debbi


apence231
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • February 22, 2018
debbiatsafe wrote:

Hi @apence23

Like erik_jan's comment, I would recommend the PDFPageFormatter.

You can place and resize your raster object to the extent that you want within the PDFPageFormatter.

Please ensure Maintain Aspect Ratio is set to 'Yes'. To check, right-click on blue part and select Properties from the drop-down menu.

Hope this helps,

Debbi

I've always had that set to 'Yes' - I'm feeling it might have something to do with the raster still itself. When I add a border around the raster its around the square of the raster not the part that I clipped:

How do I go about getting just the imagery part to fit into the extent, not the square/noData part? Basically I need it to be a rectangle (which is the shape of the clipper)

 

 


apence231
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • February 22, 2018

Too add one more what I'm experiencing - is when I remove the raster completely. The clipping box and the point shapfile that was clipped are shown here at the correct extent (hard to see blue dots but they are there):


debbiatsafe
Safer
Forum|alt.badge.img+20
  • Safer
  • February 22, 2018
apence231 wrote:
I've always had that set to 'Yes' - I'm feeling it might have something to do with the raster still itself. When I add a border around the raster its around the square of the raster not the part that I clipped:

How do I go about getting just the imagery part to fit into the extent, not the square/noData part? Basically I need it to be a rectangle (which is the shape of the clipper)

 

 

It appears like your clipped raster still has the extent of the original unclipped raster. This is not expected behaviour from the Clipper. Would you mind posting your data and workspace for a closer investigation?

 

 


apence231
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • February 22, 2018
debbiatsafe wrote:
It appears like your clipped raster still has the extent of the original unclipped raster. This is not expected behaviour from the Clipper. Would you mind posting your data and workspace for a closer investigation?

 

 

Let me know if this doesn't work for you and I can try sending again -geospatialpdf-2.fmw

 

Thanks for the help!

debbiatsafe
Safer
Forum|alt.badge.img+20
  • Safer
  • February 23, 2018
apence231 wrote:
Let me know if this doesn't work for you and I can try sending again -geospatialpdf-2.fmw

 

Thanks for the help!
In your workspace, you have Preserve Clippee Extent set to 'Yes' for your raster Clipper. This was causing your raster to retain its original extent; hence the no data part was appearing in your PDF output. Change this parameter to 'No' and you should get your expected output.

 

 

 


apence231
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • February 23, 2018
debbiatsafe wrote:

Hi @apence23

Like erik_jan's comment, I would recommend the PDFPageFormatter.

You can place and resize your raster object to the extent that you want within the PDFPageFormatter.

Please ensure Maintain Aspect Ratio is set to 'Yes'. To check, right-click on blue part and select Properties from the drop-down menu.

Hope this helps,

Debbi

I just changed the clipper setting as you have shown below and still get the same results. Not sure what I'm still missing here. Its seems to be once I rotate the raster it loses it's extent size-

 

 


apence231
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • February 23, 2018
debbiatsafe wrote:

Hi @apence23

Like erik_jan's comment, I would recommend the PDFPageFormatter.

You can place and resize your raster object to the extent that you want within the PDFPageFormatter.

Please ensure Maintain Aspect Ratio is set to 'Yes'. To check, right-click on blue part and select Properties from the drop-down menu.

Hope this helps,

Debbi

I believe I have found maybe a work-around. It might take a bit of finessing to get everything to line up, but when I just create a JPEG/raster of the extent and correct rotation to what I want (made with photoshop) and pass that through to the PDFPageFormatter on a separate input than my shapefiles its more what I'm looking for. Looks like I'll just need to make sure they are all lined up perfectly- its not a solution that I like but looks like it will work in the mean time.

 

 


Reply


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