<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??碼云GVP開源項目 12k star Uniapp+ElementUI 功能強大 支持多語言、二開方便! 廣告
                1)設置視頻采集來源為攝像頭 聲明以下屬性 ``` @property?(nonatomic, strong) NECamera?*camera;//作為外部攝像頭 @property?(nonatomic, assign) BOOLisStop; @property?(nonatomic, strong) LSVideoParaCtxConfiguration* paraCtx;//推流視頻參數設置 ``` 2)設置屬性 ``` - (void)viewWillDisappear:(BOOL)animated { _isStop= YES; ? ? [superview WillDisappear:animated]; [NEMediaCaptureEntity sharedInstance].videoParaCtx= paraCtx; } ``` paraCtx.isUseExternalCapture?= YES;//是否使用外部視頻采集,假設使用外部采集時,攝像頭的采集幀率一定要于設置的paraCtx.fps一致,同時碼率要調整為對應的碼率,對應的分辨率也需要調整 3)使用外部視頻采集 ``` if (streamparaCtx.sLSVideoParaCtx.isUseExternalCapture) { ? ? ? ? ? ? //1.從外部攝像頭獲取數據 ? ? ? ? ? ? _camera = [[NECamera alloc] initWithCameraPosition:AVCaptureDevicePositionFront captureFormat:kCVPixelFormatType_32BGRA]; ? ? ? ? ? ? _camera.delegate = self; ? ? ? ? ? ? [_camera startCapture]; ? ? } ``` 4)在NECameraDelegate的視頻渲染方法中初始化美狐shader ``` //外部采集攝像頭的數據塞回來給SDK推流 -(void)didOutputVideoSampleBuffer:(CMSampleBufferRef)sampleBuffer{ if(!_isStop){ CVPixelBufferRef pixelBuffer = CMSampleBufferGetImageBuffer(sampleBuffer); OSType formatType = CVPixelBufferGetPixelFormatType(pixelBuffer); [self.beautyManager processWithPixelBuffer:pixelBuffer formatType:formatType]; ? ? } [self.mediaCaptureexternalInputSampleBuffer:sampleBuffer]; } ```
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看