将iPhone或iPod转换为无线网络摄像头 [英] Turning an iPhone or iPod into a wireless webcam

查看:307
本文介绍了将iPhone或iPod转换为无线网络摄像头的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想将视频从iOS设备上的相机流式传输到WiFi接收机,实际上将设备变成无线网络摄像头。有没有办法构建一个小应用程序,捕获iOS应用程序上的视频输入并通过RTSP流或类似的方式发送?

I'd like to stream video from the camera on an iOS device to a receiver via wifi, in effect turning the device into a wireless webcam. Is there a way to build a small app that captures video input on an iOS app and sends it via an RTSP stream or similar?

由于这是一个特别的实验,我不关心App Store指南,如果有必要可以越狱。

As this is an ad hoc experiment, I'm not concerned about App Store guidelines and can jailbreak if necessary.

推荐答案

如果我正确地解释你的问题,需要解决四个问题:

If I interpret your question correctly you more or less need to solve four problems:


  1. 获取摄像机源。

  2. 将此转换/

  3. 防止手机锁定本身并进入深度睡眠。

第一个很简单,Apple一直提供良好的文档和示例 - > API链接。确保你查看他们的例子最后,因为你会得到一个 CMSampleBufferRef 数据对象。

The first one is fairly simple and Apple has as always provided good documentation and examples -> API link. Make sure you check out their example in the end as you will get a CMSampleBufferRef data object back.

第二部分和第三部分,您应该查看 CFNetwork framework ,特别是 CFFTPStream 以便使用FTP进行流式传输。

For the second and third part, you should check out the CFNetwork framework and specially CFFTPStream for streaming using FTP.

如果您只是自己编译,在设置中锁定功能。如果你另一方面想分发给其他用户,你可以使用一个技巧每10秒播放一个静音。这或多或少是所有闹钟在App Store中如何工作。以下是教程。 =)

If your are only building this for yourself then you can always turn off the Auto-Lock feature in the settings. If you on the other hand would like to distribute this to other users you could use a trick to play a mute sound every 10 seconds. This is more or less how all the alarm clocks work in the App Store. Here's a tutorial. =)

我希望我至少帮助了一点。
祝你好运和最好的问候!

I hope I helped a little bit at least. Good luck and best regards!

这篇关于将iPhone或iPod转换为无线网络摄像头的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆