avrcp(audio/video remote control profile)

UIControlEventTouchDown]; [self.takeButton addTarget:self action:@selector(endAction:) forControlEvents:UIControlEventTouchUpInside]; #pragma mark 视频时间少于10s松开发送 -(void)endAction:(UIButton *)sender {

UIControlEventTouchDown];


    [self.takeButton addTarget:self action:@selector(endAction:) forControlEvents:UIControlEventTouchUpInside];


#pragma mark 视频时间少于10s松开发送
-(void)endAction:(UIButton *)sender
{
  
    AVCaptureStillImageOutput *stillImageOutput = [[AVCaptureStillImageOutput alloc]init];
    NSDictionary *outputSettings = [[NSDictionary alloc] initWithObjectsAndKeys:AVVideoCodecJPEG, AVVideoCodecKey, nil];
  
    [stillImageOutput setOutputSettings:outputSettings];
  
  
  
    if ([self.captureSession canAddInput:self.captureDeviceInput]) {
      
        [self.captureSession addInput:self.captureDeviceInput];
      
    }
  
  
  
    if ([self.captureSession canAddOutput:stillImageOutput]) {
      
        [self.captureSession addOutput:stillImageOutput];

知秋君
上一篇 2024-08-16 19:02
下一篇 2024-08-16 18:36

相关推荐