Package noaa.coastwatch.util
Class BucketResamplingMapFactory
java.lang.Object
noaa.coastwatch.util.BucketResamplingMapFactory
- All Implemented Interfaces:
ResamplingMapFactory
The BucketResamplingMapFactory
class creates a resampling
map by placing the source transform earth locations into buckets and
searching the bucket contents for the closest data location to
each earth location in the destination transform.
- Since:
- 3.5.0
- Author:
- Peter Hollemans
-
Constructor Summary
ConstructorDescriptionBucketResamplingMapFactory
(EarthTransform sourceTrans, EarthTransform destTrans, ResamplingSourceImp sourceImp) Creates a new resampling factory from the source and destination transforms. -
Method Summary
Modifier and TypeMethodDescriptioncreate
(int[] start, int[] length) Creates a new resampling map that covers a specified set of destination coordinates.
-
Constructor Details
-
BucketResamplingMapFactory
public BucketResamplingMapFactory(EarthTransform sourceTrans, EarthTransform destTrans, ResamplingSourceImp sourceImp) Creates a new resampling factory from the source and destination transforms.- Parameters:
sourceTrans
- the source earth transform.destTrans
- the destination earth transform.sourceImp
- the source-specific object to use for resampling queries.- Throws:
IllegalStateException
- if the source transform had invalid earth locations when trying to determine its resolution.
-
-
Method Details
-
create
Description copied from interface:ResamplingMapFactory
Creates a new resampling map that covers a specified set of destination coordinates.- Specified by:
create
in interfaceResamplingMapFactory
- Parameters:
start
- the starting rectangle coordinates in the destination space as [row, col].length
- the size of the rectangle in destination space as [rows, cols].- Returns:
- a resampling object that covers the specified destination rectangle or null if the destination rectangle has no corresponding coordinates in the source space.
-