# How to play the audiobook .m4b file in julia?

**URL:** https://discourse.julialang.org/t/how-to-play-the-audiobook-m4b-file-in-julia/69091
**Category:** General Usage
**Tags:** web, webapps, io, file, audio
**Created:** [October 2, 2021, 2:44pm UTC](https://discourse.julialang.org/t/how-to-play-the-audiobook-m4b-file-in-julia/69091 "2021-10-02T14:44:00Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![wuxinyu](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/wuxinyu/32/28059_2.png) [@wuxinyu](https://discourse.julialang.org/u/wuxinyu)
#### Post date: [October 2, 2021, 2:44pm UTC](https://discourse.julialang.org/t/how-to-play-the-audiobook-m4b-file-in-julia/69091/1 "2021-10-02T14:44:00Z")

</div>

I want to play a audio book file `xxx.m4b` in a web app, but I can’t find a package to handle the m4b file. I find a possible package called `ffmpeg` but I have no idea how to implement it. How can I play a audio book file in a web app or just natively in my desktop?

---

<div class="post-metadata">

### Author: ![contradict](https://avatars.discourse-cdn.com/v4/letter/c/ac91a4/32.png) [@contradict](https://discourse.julialang.org/u/contradict)
#### Post date: [October 2, 2021, 3:05pm UTC](https://discourse.julialang.org/t/how-to-play-the-audiobook-m4b-file-in-julia/69091/2 "2021-10-02T15:05:19Z")

</div>

Depending on the browsers you need to support, it may work with an [`<audio>`](https://www.w3schools.com/html/html5_audio.asp) tag. Then your app just needs to serve the file with the correct mime type.

---

<div class="post-metadata">

### Author: ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)
#### Post date: [October 3, 2021, 10:59am UTC](https://discourse.julialang.org/t/how-to-play-the-audiobook-m4b-file-in-julia/69091/3 "2021-10-03T10:59:39Z")

</div>

crosspost: [web - How to play the audiobook .m4b file in julia? - Stack Overflow](https://stackoverflow.com/questions/69414209/how-to-play-the-audiobook-m4b-file-in-julia)

---

<div class="post-metadata">

### Author: ![wuxinyu](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/wuxinyu/32/28059_2.png) [@wuxinyu](https://discourse.julialang.org/u/wuxinyu)
#### Post date: [October 3, 2021, 11:27am UTC](https://discourse.julialang.org/t/how-to-play-the-audiobook-m4b-file-in-julia/69091/4 "2021-10-03T11:27:53Z")

</div>

Can I use julia to control the playback? Like the start time or speed. I want it to be a web stream. It is like user click a bottom on the web page and send a http post to julia, and the julia control the web stream? I’m wondering how to get the .m4b file to a audio stream and connect the stream to the web.
