Class: GDAL::RPCInfo

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/gdal/rpc_info.rb

Overview

Wrapper for FFI::GDAL::RPCInfo.

Instance Method Summary collapse

Constructor Details

#initialize(struct_or_ptr = nil) ⇒ RPCInfo

Returns a new instance of RPCInfo.

Parameters:



16
17
18
19
20
21
22
23
24
25
# File 'lib/gdal/rpc_info.rb', line 16

def initialize(struct_or_ptr = nil)
  @c_struct = case struct_or_ptr
              when FFI::GDAL::RPCInfo
                struct_or_ptr
              when FFI::Pointer
                FFI::GDAL::RPCInfo.new(struct_or_ptr)
              else
                FFI::GDAL::RPCInfo.new
              end
end

Instance Method Details

#c_pointerFFI::Pointer

Returns:

  • (FFI::Pointer)


28
29
30
# File 'lib/gdal/rpc_info.rb', line 28

def c_pointer
  @c_struct.to_ptr
end

#to_metadataArray<String>

Returns:



33
34
35
# File 'lib/gdal/rpc_info.rb', line 33

def 
  FFI::GDAL::Alg.RPCInfoToMD(@c_struct).read_array_of_string(0)
end