Twinside / Juicy.Pixels

Haskell library to load & save pictures
BSD 3-Clause "New" or "Revised" License
238 stars 57 forks source link

Refine(cast) DynamicImage to specific Image #203

Open ingun37 opened 2 years ago

ingun37 commented 2 years ago

Maybe I haven't read doc enough and if that's the case I'm sorry😭 but I can't find a way to refine DynamicImage to specific Image type, preferably using Lens?

I read HDR image using decodeHDR but it returns as DynamicImage. I want to refine it to ImageRGBF. How can I do it?

Side note: I feel bad asking trivial question in Issues. Maybe you guys should open up Github Discussion

ingun37 commented 2 years ago

I'm currently using constructor matching