Sha256: 7c81ef05095f8cdea9a23c0d0f501efad95a6ca68585a609399db131ab7eea6c
Contents?: true
Size: 819 Bytes
Versions: 3
Compression:
Stored size: 819 Bytes
Contents
# frozen_string_literal: true module GDAL class Dataset module Matching # @param other_dataset [GDAL::Dataset] # @param options [Hash] # @return [Hash{count => Integer, gcp: => FFI::GDAL::GCP}] Not sure why, # but the C function seems to return a single GCP instead of an Array of # them. def compute_matching_points(other_dataset, **options) other_dataset_ptr = GDAL._pointer(GDAL::Dataset, other_dataset) options_ptr = GDAL::Options.pointer(options) gcp_count_ptr = FFI::MemoryPointer.new(:int) gcp = FFI::GDAL::Matching.GDALComputeMatchingPoints( @c_pointer, other_dataset_ptr, options_ptr, gcp_count_ptr ) { count: gcp_count_ptr.read_int, gcp: gcp } end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
ffi-gdal-1.1.0 | lib/gdal/dataset/matching.rb |
ffi-gdal-1.0.4 | lib/gdal/dataset/matching.rb |
ffi-gdal-1.0.3 | lib/gdal/dataset/matching.rb |