Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/unstoppable/actionscript-exif-reading-lib
photo exif reading lib for actionscript3/flash
https://github.com/unstoppable/actionscript-exif-reading-lib
Last synced: about 2 months ago
JSON representation
photo exif reading lib for actionscript3/flash
- Host: GitHub
- URL: https://github.com/unstoppable/actionscript-exif-reading-lib
- Owner: unstoppable
- Created: 2012-06-10T03:01:38.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2012-06-10T03:15:50.000Z (over 12 years ago)
- Last Synced: 2024-08-04T05:02:58.453Z (5 months ago)
- Language: ActionScript
- Size: 1.73 MB
- Stars: 6
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-actionscript-sorted - as3-exif-lib - AS3 library to read JPEG EXIF data (File Formats / Misc Formats)
README
actionscript-exif-reading-lib
=============================photo exif reading lib for actionscript3/flash
How to use this lib to get the photo's orientation:
`
import flash.utils.ByteArray;
import fox.photo.SimpleExifExtractor;
import fox.photo.exif.ifd.IFDValue;
import fox.photo.jpeg.Exif;var orientation:int = -1;
var orientationId:int = 274;// in Exif2-2.PDF document, the orientation id is 274
var bytes:ByteArray = PhotoData;
var exif:Exif=SimpleExifExtractor.readExif(bytes);
var tag:IFDValue=exif.findTagById(orientationId);
if (tag) // in certain case, it might don't have orientation infomation.
{
orientation=parseInt("" + tag.value);
}
trace('orientation is:'+orientation);
`