小编Ren*_*Tan的帖子

如何将CIFilter输出到Camera视图?

我刚刚开始使用Objective-C,我正在尝试创建一个简单的应用程序,它会显示带有模糊效果的摄像机视图.我让Camera输出与AVFoundation框架一起工作.现在,我正在尝试连接核心图像框架,但不知道如何,Apple文档让我感到困惑,在线搜索指南和教程导致没有结果.在此先感谢您的帮助.

#import "ViewController.h"
#import <AVFoundation/AVFoundation.h>
@interface ViewController ()

@property (strong ,nonatomic) CIContext *context;

@end

@implementation ViewController
AVCaptureSession *session;
AVCaptureStillImageOutput *stillImageOutput;

-(CIContext *)context
{
    if(!_context)
    {
        _context = [CIContext contextWithOptions:nil];
    }
    return _context;
}
- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
}

-(void)viewWillAppear:(BOOL)animated{
    session = [[AVCaptureSession alloc] init];
    [session setSessionPreset:AVCaptureSessionPresetPhoto];

    AVCaptureDevice *inputDevice = [AVCaptureDevice defaultDeviceWithMediaType:AVMediaTypeVideo];
    NSError *error;
    AVCaptureDeviceInput *deviceInput = [AVCaptureDeviceInput deviceInputWithDevice:inputDevice error:&error];

    if ([session canAddInput:deviceInput]) {
        [session addInput:deviceInput];
    } …
Run Code Online (Sandbox Code Playgroud)

objective-c avfoundation ios cifilter ciimage

8
推荐指数
1
解决办法
3535
查看次数

Sugar CRM-无法在“模块”构建器上创建新字段

我很难弄清楚为什么我无法在Sugar CRM CE的模块生成器上创建新字段。

我以为这可能是文件权限问题,但是经过SugarCRM社区的许多论坛帖子和用户指南之后,我仍未解决问题。

To give a background on the issue, here are steps I've taken:

  1. I installed a Debian image on a VM
  2. Updated the packages and installed a LAMP server (with PHP 5.6)
  3. Downloaded the required prerequisite modules
  4. Configured the php.ini as per the installation guide
  5. Ran 'chown -R www-data:www-data /var/www/html/sugarcrm'
  6. Ran 'chmod 775 -R /var/www/html/sugarcrm'
  7. Ran the installation page of Sugar (Setup went well until the Registration page where it just outputs 'Permission Denied')
  8. Create a new …

php debian sugarcrm

1
推荐指数
1
解决办法
368
查看次数

标签 统计

avfoundation ×1

cifilter ×1

ciimage ×1

debian ×1

ios ×1

objective-c ×1

php ×1

sugarcrm ×1