public
Description: A lightweight module designed to extract the width/height dimensions of various image types. Also supports SWFs
Homepage: http://code.google.com/p/ruby-imagespec/
Clone URL: git://github.com/andersonbrandon/ruby-imagespec.git
name age message
file LICENSE Tue Feb 17 20:01:51 -0800 2009 Moved everything out of the image_spec dir [GMFlash]
file README Sat Feb 28 12:00:14 -0800 2009 Added example for content_type attribute [GMFlash]
file Rakefile Tue Feb 17 20:01:51 -0800 2009 Moved everything out of the image_spec dir [GMFlash]
file init.rb Thu Feb 26 14:45:40 -0800 2009 Abstracted parsing [GMFlash]
directory lib/ Thu Mar 05 01:00:48 -0800 2009 Woops! CONTENT_TYPE should be in the SWF namesp... [GMFlash]
directory tasks/ Tue Feb 17 20:01:51 -0800 2009 Moved everything out of the image_spec dir [GMFlash]
directory test/ Tue Feb 17 20:01:51 -0800 2009 Moved everything out of the image_spec dir [GMFlash]
README
ImageSpec
=========

ImageSpec is a lightweight module designed to extract width/height dimensions from most standard image formats, as well 
as SWFs.

This is a work in progress.  I intend on expanding this to include other details (EXIF, various metadata, etc.) as well.



Example
=======

# From a file in your file system
instance = ImageSpec.new('/path/to/your/file')

# From a URL
instance = ImageSpec.new('http://example.com/image.png')

# From an IO stream
file = File.new('/path/to/your/file', 'rb')
instance = ImageSpec.new(file)

instance.width
instance.height
instance.content_type

Pretty simple, huh?

Copyright (c) 2008 Brandon Anderson, released under the MIT license

Contributions by Michael Sheakoski and Mike Boone