Tag: 目标C

如何加快移动设备统一build设和运行stream程iOS / Android

您好我正在开发一个游戏统一,我需要在iOS中testing这个游戏。 对于特定的情况,我需要testing控制器的input触摸,但这需要花费很多时间。 当我改变脚本C#中的一些代码行时,我必须重新构buildiOS游戏,之后我必须构build并运行Xcode项目进行testing并在我的iPhone上运行游戏。 这个过程需要很长时间,所以问题是如果有一些方法来加速这个过程?

在c ++中使用OpenCV 2.4计算凸性缺陷

我使用OpenCV 2.4来计算图像的凸包。 我也在做一些处理,从图像中去除一些噪音,这与问题无关。 计算凸面的代码如下: … cv::Mat sourceImage; // assume something is already here please cv::vector<cv::Vec4i> hierarchy; std::vector<std::vector<cv::Point> > contours; cv::findContours( sourceImage, contours, hierarchy, CV_RETR_TREE, CV_CHAIN_APPROX_SIMPLE,cv::Point(0, 0)); // Find the convex hull object for each contour vector<cv::vector<cv::Point> >hull( contours.size() ); for (int i = 0; i < contours.size(); i++) { convexHull( contours[i], hull[i], false ); } […]

malloc:***错误:不正确的校验和被释放的对象 – 对象被释放后可能被修改

我的iOS应用程序有一个很大的问题:它有时会崩溃,没有详细的debugging错误。 堆栈跟踪是空的。 这些是堆栈跟踪中唯一的两行: 在UIApplicationMain的“符号存根: – [_ UIHostedTextServiceSession dismissTextServiceAnimated:]”开始崩溃。 并报告“libsystem_c.dylib`malloc_error_break”。 在com.apple.main-thread 。 Xcodedebugging器(连接设备)上的错误: malloc: *** error for object 0x208a7614: incorrect checksum for freed object – object was probably modified after being freed. *** set a breakpoint in malloc_error_break to debug 我用libsystem_c.dylib在malloc_error_break中设置了一个断点,没有任何debugging器的反馈。 我不知道要解决这个问题。

由于Facebook SDK和Flurry SDK中的advertisingIdentifier而被拒绝的应用程序

我的应用程序被拒绝,因为在Facebook的SDK和Flurry SDK的advertisingIdentifier ! 我在最新的Facebook SDK (3.12)和Flurry SDK中发现了一个advertisingIdentifier事件。 也许你可以使用下面的方法检查你的图书馆的发生: 我在terminal打开了FacebookSDK.framework作为一个库,然后input以下命令 otool -v -s __TEXT __objc_methname FacebookSDK | grep advertisingIdentifier 和Flurry SDK一样。 但我不知道该怎么办。 新闻:Flurry最近更新了他们的SDK,不包含“advertisingIdentifier”,但Facebook还没有。

Xcode 4 / iOS – 从我的应用程序内使用SMTP发送电子邮件

我一直在寻找一个框架,只是让我从我的应用程序内发送电子邮件。 我已经试过MailCore,Pantomime和SKPSMTP都没有运气。 我无法让他们在Xcode编译,所以我推测他们已经过时了。 有什么办法可以做到这一点? 如果是这样,怎么样? 谢谢。

如何以编程方式设置设备(UI)方向?

希望屏幕上的所有内容(UI)能够从左到右旋转或反过来。 我怎么去做这个? 这是私人的吗? 我知道 -(BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {} 可以让你说出UI的取向,但是有办法一次只强制一个? 干杯

自动透视校正OpenCV

我试图在我的iOS程序中实现自动透视校正,当我使用我在教程中find的testing图像时,一切正常。 但是当我拍摄一张照片时,我收到了一个奇怪的结果。 我正在使用本教程中的代码 当我给它看起来像这样的图像: 我得到这个结果: 这是什么dst给我可能有所帮助。 我正在使用这个来调用包含代码的方法。 quadSegmentation(Img, bw, dst, quad); 任何人都可以告诉我,当我得到如此多的绿线相比,教程? 而我怎么能够解决这个问题,并适当裁剪图像只包含卡?

如何从iphone中删除NSString中的HTML标记?

我正在工作日历function为我的应用程序UITextview我今天点击date或明天的date或一些其他date需要在UITextview显示吉祥的细节。我一直在尝试格式化我的文本视图中的string,但我无法工作出来。 我很新的xcode.I想要删除我的stringResonse中的HTML标签,并显示在UITextview 。 我在我的代码中是这样写的: -(void)connectionDidFinishLoading:(NSURLConnection *)connection { [UIApplication sharedApplication].networkActivityIndicatorVisible=NO; if(connection==urlConnection) { NSString *strResponse=[[NSString alloc]initWithData:responseData encoding:NSUTF8StringEncoding]; NSLog(@"String Response is : %@",strResponse); NSMutableString *mutString=[NSMutableString string]; NSString *s=nil; NSString *s1=nil; //NSArray *arr1=[strResponse componentsSeparatedByCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"<br>"]]; NSArray *arr2=[strResponse componentsSeparatedByString:@"\n"]; NSLog(@"array %@",arr2); for(s in arr2) { s = [s stringByReplacingOccurrencesOfString: @"<br>" withString: @"\n"]; s1=[s stringByReplacingOccurrencesOfString:@"<font color>" withString:@" "]; [mutString appendString:@""]; [mutString […]

以编程方式添加导航栏iOS

我正在尝试使用导航栏(后退button,标题等)和选项卡栏(底部的工具栏)制作应用程序。 我使用子视图,所以我不必担心状态栏,导航栏,标签栏高度等,但我认为这是我的麻烦,因为我似乎无法弄清楚如何设置导航栏和制表符栏。 这是我的。 我究竟做错了什么? AppDelegate.h (default for single view app) AppDelegate.m (default for single view app) ViewController.h #import <UIKit/UIKit.h> @interface ViewController : UIViewController @property (strong, nonatomic) UIView *contentSubview; @end ViewController.m #import "ViewController.h" @interface ViewController () @end @implementation ViewController – (void)loadView{} – (void)viewDidLoad { [super viewDidLoad]; UIView *view = [[UIView alloc] init]; view.backgroundColor = [UIColor greenColor]; […]

在Xcode 4.2中启用崩溃日志符号

我正在使用Xcode 4.2,我的崩溃日志没有得到象征。 如何在Xcode 4.2中启用它?