# Get DCT coefficients of jpeg image

**URL:** https://discourse.julialang.org/t/get-dct-coefficients-of-jpeg-image/64640
**Category:** Visualization
**Tags:** question, images
**Created:** [July 14, 2021, 3:08pm UTC](https://discourse.julialang.org/t/get-dct-coefficients-of-jpeg-image/64640 "2021-07-14T15:08:24Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![stevengj](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stevengj/32/71_2.png) [@stevengj](https://discourse.julialang.org/u/stevengj)
#### Post date: [July 14, 2021, 4:46pm UTC](https://discourse.julialang.org/t/get-dct-coefficients-of-jpeg-image/64640/2 "2021-07-14T16:46:07Z")

</div>

Glancing at Sallee’s source code, it seems to be a very thin Matlab MEX wrapper around [libjpeg](http://libjpeg.sourceforge.net/), which is a popular C library to access JPEG files.

It should be pretty easy to write a Julia package to call libjpeg, or even just a few lines to extract the information you specifically want. We _already_ have a Yggdrasil package ([JpegTurbo\_jll](https://juliahub.com/ui/Packages/JpegTurbo_jll/EC0Oy/2.1.0+0?t=0)) to provide a compiled libjpeg binary.

In the meantime you could try one of the Python libjpeg-based libraries, which can be called from Julia via PyCall.

---

_[View the full topic](https://discourse.julialang.org/t/get-dct-coefficients-of-jpeg-image/64640)._
