Skip to main content
Question

best way to extract raster from geometry


kidega
Contributor
Forum|alt.badge.img+8

Hi,

I wounder what the best way could be to extract raster from geometry? In this case, extract an ortophoto from a terrain mesh. I have tried the AppearanceExtractor which works fine. The aim is to extract the ortophoto and write it as a jpeg, then read it in the workflow and replace it on the terrain via AppearanceSetter. Works fine, but I only need one feature (face) which contains the ortophoto to write to jpeg. In one test the terrain contains 62 faces, so I use the sampler to sample First N Features to get the first face and ortophoto. The problem I find is that all other 61 faces need to be processed to output "NotSampled". So depending on the terrain mesh and no. of faces this could take quite some time. I wounder if First N Feature is found, then stop processing rest of features?

Hope it makes sense. Thanks!

2 replies

  • October 21, 2020

Hi, the sampler performance won't really change between 1 or 62 raster features. What will take away performance is actually reading 62 rasters instead of only 1. Maybe you could use the "Max Features to Read" parameter in your reader ? That would let you read only 1 feature instead of processing them all. Hope this help.


kidega
Contributor
Forum|alt.badge.img+8
  • Author
  • Contributor
  • November 1, 2020
alexist wrote:

Hi, the sampler performance won't really change between 1 or 62 raster features. What will take away performance is actually reading 62 rasters instead of only 1. Maybe you could use the "Max Features to Read" parameter in your reader ? That would let you read only 1 feature instead of processing them all. Hope this help.

Hi @alexist​ 

Thanks for this reccomendation. It helped alot!


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