class GDAL::Transformers::ReprojectionTransformer
Attributes
c_pointer[R]
@return [FFI::Pointer] C pointer to the C reprojection transformer.
Public Class Methods
function()
click to toggle source
@return [FFI::Pointer]
# File lib/gdal/transformers/reprojection_transformer.rb, line 7 def self.function FFI::GDAL::Alg::ReprojectionTransform end
new(source_wkt, destination_wkt)
click to toggle source
@param source_wkt [String] @param destination_wkt [String]
# File lib/gdal/transformers/reprojection_transformer.rb, line 23 def initialize(source_wkt, destination_wkt) pointer = FFI::GDAL::Alg.GDALCreateReprojectionTransformer(source_wkt, destination_wkt) @c_pointer = FFI::AutoPointer.new(pointer, ReprojectionTransformer.method(:release)) end
release(pointer)
click to toggle source
@param pointer [FFI::Pointer]
# File lib/gdal/transformers/reprojection_transformer.rb, line 12 def self.release(pointer) return unless pointer && !pointer.null? FFI::GDAL::Alg.GDALDestroyReprojectionTransformer(pointer) end
Public Instance Methods
destroy!()
click to toggle source
# File lib/gdal/transformers/reprojection_transformer.rb, line 29 def destroy! ReprojectionTransformer.release(@c_pointer) @c_pointer = nil end
function()
click to toggle source
@return [FFI::Pointer]
# File lib/gdal/transformers/reprojection_transformer.rb, line 36 def function self.class.function end