Class: ADIWG::Mdtranslator::Writers::Simple_html::Html_ImageInfo

Inherits:
Object
  • Object
show all
Defined in:
lib/adiwg/mdtranslator/writers/simple_html/sections/html_imageInfo.rb

Instance Method Summary collapse

Constructor Details

#initialize(html) ⇒ Html_ImageInfo

Returns a new instance of Html_ImageInfo.



17
18
19
# File 'lib/adiwg/mdtranslator/writers/simple_html/sections/html_imageInfo.rb', line 17

def initialize(html)
   @html = html
end

Instance Method Details

#writeHtml(hImage) ⇒ Object



21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
# File 'lib/adiwg/mdtranslator/writers/simple_html/sections/html_imageInfo.rb', line 21

def writeHtml(hImage)

   # classes used
   identifierClass = Html_Identifier.new(@html)
   
   # image information - illumination elevation angle
   unless hImage[:illuminationElevationAngle].nil?
      @html.em('Illumination elevation angle: ')
      @html.text!(hImage[:illuminationElevationAngle].to_s)
      @html.br
   end

   # image information - illumination azimuth angle
   unless hImage[:illuminationAzimuthAngle].nil?
      @html.em('Illumination azimuth angle: ')
      @html.text!(hImage[:illuminationAzimuthAngle].to_s)
      @html.br
   end

   # image information - image condition
   unless hImage[:imageCondition].nil?
      @html.em('Image condition: ')
      @html.text!(hImage[:imageCondition])
      @html.br
   end

   # image information - cloud cover percentage
   unless hImage[:cloudCoverPercent].nil?
      @html.em('Cloud cover percentage: ')
      @html.text!(hImage[:cloudCoverPercent].to_s)
      @html.br
   end

   # image information - compression generation quantity
   unless hImage[:compressionQuantity].nil?
      @html.em('Compression generation quantity: ')
      @html.text!(hImage[:compressionQuantity].to_s)
      @html.br
   end

   # image information - image quality code {identifier}
   unless hImage[:imageQualityCode].empty?
      @html.div do
         @html.div('Image Quality Code', {'class' => 'h5'})
         @html.div(:class => 'block') do
            identifierClass.writeHtml(hImage[:imageQualityCode])
         end
      end
   end

   # image information - triangulation information available {Boolean}
   @html.em('Triangulation information available: ')
   @html.text!(hImage[:triangulationIndicator].to_s)
   @html.br

   # image information - radiometric calibration information available {Boolean}
   @html.em('Radiometric calibration available: ')
   @html.text!(hImage[:radiometricCalibrationAvailable].to_s)
   @html.br

   # image information - camera calibration information available {Boolean}
   @html.em('Camera calibration information available: ')
   @html.text!(hImage[:cameraCalibrationAvailable].to_s)
   @html.br

   # image information - film distortion information available {Boolean}
   @html.em('Film distortion information available: ')
   @html.text!(hImage[:filmDistortionAvailable].to_s)
   @html.br

   # image information - lens distortion information available {Boolean}
   @html.em('Lens distortion information available: ')
   @html.text!(hImage[:lensDistortionAvailable].to_s)
   @html.br

end