问题标签 [pbjvision]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
1 回答
184 浏览

ios - PBJVISION - 从 cameraMode.Video 切​​换到 cameraMode.Photo 时出错

我在我的 Instagram 应用程序中使用“PBJVISION”,例如触控录制功能。它工作正常,但是当我尝试从 PBJCameraMode.Video 切​​换到 PBJCameraMode.Photo 时,我收到一个错误;

原因:-[AVCaptureStillImageOutput captureStillImageAsynchronouslyFromConnection:completionHandler:] - 不一致的状态。

我的代码非常简单;

你能帮我么?

谢谢,E。

0 投票
1 回答
113 浏览

ios - 视频捕捉垂直输出 iOS

我正在尝试使用PBJVision捕获视频。

我这样设置相机

这会产生输出1280x720where 1280is width

将方向设置为Landscape旋转流。

我一直在尝试用GPUImage录制视频,我可以

这样我得到垂直输出。

我想实现 PBJVision 的垂直输出,因为我遇到了 GPUImage 将视频写入磁盘的问题。(我会为此提出另一个问题)。

什么方法/属性AVFoundation负责提供垂直输出而不是水平输出?

抱歉这个问题,我已经用谷歌搜索了 2 天 - 找不到答案。

0 投票
1 回答
755 浏览

swift - 将视频保存到解析和播放

所以我正在使用这个自定义类来录制我的视频——https://github.com/piemonte/PBJVision。我正在尝试在我的 iOS 应用程序中录制视频,但我似乎无法正确获取代码以将文件上传到我的解析服务器。一些东西:

  • 在 PBJVision 类中,它允许您在录制视频后使用 NSURL(fileWithPath:videoPath) 访问资产。

  • 要访问资产中的数据并保存到 Parse,我使用以下函数:

    }

然后我使用 UITableView 显示来自 Parse 的数据。下面是我如何从 Parse 中检索我的资产并进入我的 AVPlayer(): // 为反应创建播放器 let player = Player() player.delegate = self player.view.frame = CGRectMake(0.0, nameLabel.frame.origin. y + nameLabel.frame.size.height + 0.0, self.view.frame.width, 150) player.view.backgroundColor = UIColor.whiteColor()

我复制从 urlFromParse 返回的值(http://parlayapp.herokuapp.com/parse/files/smTrXDGZhlYQGh4BZcVvmZ2rYB9kA5EhPkGbj2R2/58c0648ae4ca9900f2d835feb77f165e_file.mp4)并将其粘贴到我的浏览器中,视频在浏览器中播放。我是否正确假设文件已正确保存?

当我去运行我的应用程序时,视频不播放。关于我做错了什么有什么建议吗?

0 投票
0 回答
670 浏览

ios - PBJVision CMTimeMakeWithSeconds(1.094 秒,时间刻度 24)

我在一个快速项目中使用 PBJVision 在结束捕获会话时遇到以下问题。

CMTimeMakeWithSeconds(1.094 秒,时间刻度 24):警告:由于时间刻度非常低,引入了 -0.011 的错误

这不允许我将视频保存到照片并在保存时给我以下错误:

错误域=NSCocoaErrorDomain 代码=-1 "(null)"

我已经搜索了很多但没有找到解决方案。

这是我的代码

0 投票
1 回答
715 浏览

ios - 在 Swift 中使用 PBJVideoPlayer pod 应用 PhotoEffectNoir 过滤器来播放视频

我正在尝试将黑白效果添加到使用 PBJVideoPlayer pod 快速播放的视频中。我已经设置好了,所以用户可以点击一个按钮来应用过滤器。我想我的问题来了,因为我不确定 AVVIdeoComposition 的模拟对于吊舱来说是什么。任何见解将不胜感激。

0 投票
1 回答
178 浏览

ios - 在 iOS 10 上使用 PBJVideoPlayer 时出现黑色视频

我正在使用 PBJVideoPlayer 在我的 iOS 应用程序上显示视频,使用以下代码:

在大约 50% 的时间里,视频显示为黑色,而声音很好。

边界很好(因为我确实看到了一个黑匣子)并且视频路径很好,因为我确实创建了正确的视频。

我正在使用装有 iOS 10 的设备,但我仍然没有装有旧版 iOS 的设备来检查..

任何想法可能是什么问题?我看过其他关于黑色视频的问题,但没有一个有帮助。

0 投票
1 回答
455 浏览

ios - Video No Longer Recording Audio (PBJVision/AVFoundation)

I have an app (enterprise, distributed OTA) that among other things records video clips. All of a sudden, we started getting video uploads that were missing audio, and this issue now seems to be totally reproducible. I've been using the PBJVision library, which had seemed to work great, but I have also tested this with SwiftyCam (another AVFoundation-based library) with same results. It's unclear exactly when this was introduced, but I've checked the following:

  • Ensure that a NSMicrophoneUsageDescription is set in the target .plist
  • Ensure that camera and microphone permissions are showing as granted in system settings
  • Try disabling microphone permissions in settings (app correctly prompts the user to re-enable permissions)
  • Try earlier releases of the video capture library in case of regression
  • Try different video capture library
  • Explicitly set audio enabled and bitrate for PBJVision/SwiftyCamera, and ensure that the session is at least reporting that it has audio in the logs (that is, the library and AVFoundation think there's an input set up, with an input stream that's being handled)
  • Take a video with the system camera, and upload through the app — in this case, audio does work (it's not a problem with the hardware)
  • Reset all content and permissions on a device, to make sure there isn't some kind of cached permission hanging out
  • Make sure volume is not muted

The copy that gets saved to the camera roll is also silent, so it's not happening when the video gets uploaded. I also started to implement recording using just AVFoundation, but don't want to waste time if that will produce the same results. What could be causing a particular app not to record audio with video? I have looked at related questions, and none of the solutions provided address the problem I'm having here.

EDIT:

Here are the logs that appear when starting, recording, and stopping a PBJVision session:

0 投票
0 回答
57 浏览

ios - iPhone 11/12 PBJVision 框架上的相机会话问题

我正在为我的相机使用PBJVision 框架。我正在我的 iPhone 11/12 上进行测试。(此问题在 iPhone 11-12 之前的任何 iPhone 上都不会发生)(iOS 14.4.2)

问题是当我开始长时间按住并捕捉视频时。它会记录我采取行动之前的 1-2 秒。

音频不会记录前 1-2 秒,但视频会。此外,当我停止捕获时,录制的视频将冻结最后 1-2 秒,但音频将播放到最后。

这是我重现该问题的视频。

我不确定为什么这只发生在 iPhone 11-12 上。我已针对此问题发布了 Upwork 工作,并将奖励第一个找到解决方案的人。

0 投票
1 回答
45 浏览

swift - Swift: Parse does not load a video from URL

I am trying to stream a video from backend to my device.I have a video url from backend but screen displays nothing. However, youtube url it works. Can anyone guide me why this video is not playing and how can it be played? I am using pod 'YouTubePlayer' to play the video.