Righto,

I'll have a crack and submit a pull request when I'm done.

Thanks,
Mark

On Thu, Oct 3, 2013 at 6:07 PM, Larry Gritz <[email protected]> wrote:
> I don't think this merits a new core type.
>
> I would add it to the metadata as an array of two unsigned ints, which is
> how it's encoded in Imf::TimeCode.  You'd want something like this in
> exrinput.cpp:
>
> static TypeDesc TwoUints (TypeDesc::UINT, 2);
> Imf::TimeCode tc = ...;  // get the timecode from the EXR file
> spec.attribute ("openexr:TimeCode", TwoUints, &tc);
>
> And then to extract it (including in exroutput.cpp):
>
> ImageIOParameter *f = spec.find_attribute ("openexr:TimeCode", TwoUints);
> if (f) {
>     Imf::TimeCode tc = *(const ImfTimeCode *) f->data();
>     ... do your thing with tc ...
> }
>
>
>
> On Oct 3, 2013, at 8:56 AM, Mark Boorer wrote:
>
> Hi,
>
> Was just looking to access timecode metadata from some EXR files, and
> noticed that timecode keys aren't extracted by the reader.
>
> I then found this rather old issue
> https://github.com/OpenImageIO/oiio/issues/337. Is it possible for me to add
> this in? A simple class based on ImfTimeCode.h (or even just this class
> directly) and a new enum added to TypeDesc?
>
> Cheers,
> Mark
>
>
> --
> Larry Gritz
> [email protected]
>
>
>
> _______________________________________________
> Oiio-dev mailing list
> [email protected]
> http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org
>
_______________________________________________
Oiio-dev mailing list
[email protected]
http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org

Reply via email to