【问题标题】:Reading EXIF data from Canon EOS D7 with EXIF-AS3 in Actionscript 3在 Actionscript 3 中使用 EXIF-AS3 从 Canon EOS D7 读取 EXIF 数据
【发布时间】:2013-01-22 01:50:24
【问题描述】:

我在 stackoverflow 上的第一篇文章,我之前多次使用过 EXIF-AS3 类(Adobe Flash CS5 和 AS3),它总是有效,我指的是这个类:

http://active.tutsplus.com/tutorials/actionscript/quick-tip-use-as3-to-grab-exif-data-from-a-jpg-image/ http://code.google.com/p/exif-as3/

我遍历 EXIF 数据以查找相机的序列号,但是在新佳能上我似乎无法在任何地方找到此序列号。似乎序列号存储在 MarkerNotes 中,但我不认为班级正在阅读它:

if (exifLoader.exif.ifds.primary)
        {
            displayIFD(exifLoader.exif.ifds.primary);
        }
        if (exifLoader.exif.ifds.exif)
        {
            displayIFD(exifLoader.exif.ifds.exif);
        }
        if (exifLoader.exif.ifds.gps)
        {
            displayIFD(exifLoader.exif.ifds.gps);
        }
        if (exifLoader.exif.ifds.interoperability)
        {
            displayIFD(exifLoader.exif.ifds.interoperability);
        }
        if (exifLoader.exif.ifds.thumbnail)
        {
            displayIFD(exifLoader.exif.ifds.thumbnail);
        }

有什么建议或方法让我继续前进吗?

【问题讨论】:

  • 更新:我看到序列号存储在命名空间 aus 而不是 exif。
  • 嗯,好像 Adob​​es 的命名空间不见了。例如:cssdk.host.adobe.com/sdk/1.5/docs/WebHelp/references/XMPASLib/…
  • 意味着该列表中的大多数命名空间都转到了损坏的链接页面。有人知道这些命名空间现在存储在哪里吗?

标签: actionscript-3 exif


【解决方案1】:

我对 Exif 对象的构成不太熟悉,但我猜如果“MarkerNotes”是元信息的一个属性,它可以像这样访问:

if (exifLoader.exif.ifds.markerNotes) {
  displayIFD(exifLoader.exif.ifds.markerNotes);
}

似乎代码正在检查非空值,然后将数据发送到显示传入标签的方法。

【讨论】:

  • 您好,感谢您的回复。我现在几乎在那里,它出现在较新的佳能相机上,例如佳能 EOS D7,它存储 EXIF 数据和 XMP 数据。序列号存储在 aus 命名空间下。希望有一天这对某人有所帮助。当我弄清楚为什么 XMP 没有加载到这组图片上时,将标记为已完成。
  • Google 提供了一些提取 XMP 信息的替代方法:google.co.uk/…
  • 已解决:我使用了 de.qwesda.as3_xmp_file.as3_xmp_file 类,效果很好。
  • [code]var fileXmp:as3_xmp_file = new as3_xmp_file(picLoad); var dc_exif:命名空间 = XMPConst.aux; //序列号 = 文件 Xmp.xmp。 if (fileXmp.xmp.dc_exif::SerialNumber != null) { serialNumber = fileXmp.xmp.dc_exif::SerialNumber }
猜你喜欢
  • 2012-05-16
  • 1970-01-01
  • 2020-04-22
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2012-04-29
  • 1970-01-01
相关资源
最近更新 更多