Class: FastImage::Exif

Inherits:
Object
  • Object
show all
Defined in:
lib/fastimage.rb

Overview

:nodoc:

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(stream) ⇒ Exif

Returns a new instance of Exif.



939
940
941
942
943
# File 'lib/fastimage.rb', line 939

def initialize(stream)
  @stream = stream
  @width, @height, @orientation = nil
  parse_exif
end

Instance Attribute Details

#heightObject (readonly)

Returns the value of attribute height.



937
938
939
# File 'lib/fastimage.rb', line 937

def height
  @height
end

#orientationObject (readonly)

Returns the value of attribute orientation.



937
938
939
# File 'lib/fastimage.rb', line 937

def orientation
  @orientation
end

#widthObject (readonly)

Returns the value of attribute width.



937
938
939
# File 'lib/fastimage.rb', line 937

def width
  @width
end

Instance Method Details

#rotated?Boolean

Returns:

  • (Boolean)


945
946
947
# File 'lib/fastimage.rb', line 945

def rotated?
  @orientation >= 5
end