# How to use opencv2 Add ffmpeg to the framework?

**URL:** <https://forum.opencv.org/t/how-to-use-opencv2-add-ffmpeg-to-the-framework/7904>\
**Category:** Uncategorized\
**Tags:** ffmpeg, build, apple\
**Created:** [March 12, 2022, 3:48pm UTC](https://forum.opencv.org/t/how-to-use-opencv2-add-ffmpeg-to-the-framework/7904 "2022-03-12T15:48:43Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![YSH](https://avatars.discourse-cdn.com/v4/letter/y/df788c/32.png) [@YSH](https://forum.opencv.org/u/YSH)\
**Post date:** [March 12, 2022, 3:48pm UTC](https://forum.opencv.org/t/how-to-use-opencv2-add-ffmpeg-to-the-framework/7904/1 "2022-03-12T15:48:43Z")

</div>

Hello, everyone. I read and processed the MJPEG stream of IPCAM using OpenCV on windows. Then I transplanted the program to IOS and downloaded opencv2 Appears after the framework is compiled and executed

OpenCV(4.5.4) /Volumes/build-storage/build/master\_ iOS-mac/opencv/modules/videoio/src/cap\_ images. cpp:253: error: (-5:Bad argument) CAP\_ IMAGES: can’t find starting number (in the name of file): [http://10.3.141.1:8080/?action=stream](http://10.3.141.1:8080/?action=stream) in function ‘icvExtractPattern’

The same message appeared on the window because of the lack of ffmpeg dll  
So I recompiled the ffmpeg static function library of IOS and opencv2 framework  
But how can I add the ffmpeg library to opencv2 framework ？
