33 #ifndef DOXYGEN_SHOULD_SKIP_THIS 35 #import <Foundation/Foundation.h> 37 #import "ImageDisplay.h" 39 @implementation ImageDisplay
49 UIGraphicsBeginImageContext(image.size);
52 [image drawAtPoint:CGPointMake(0,0)];
55 CGContextRef context = UIGraphicsGetCurrentContext();
56 CGContextSetLineWidth(context, tickness);
57 CGContextSetStrokeColorWithColor(context, [color CGColor]);
59 CGContextMoveToPoint(context, ip1.get_u(), ip1.get_v());
60 CGContextAddLineToPoint(context, ip2.get_u(), ip2.get_v());
62 CGContextStrokePath(context);
65 UIImage *retImage = UIGraphicsGetImageFromCurrentImageContext();
68 UIGraphicsEndImageContext();
80 :(
double) size :(
int)tickness
82 UIGraphicsBeginImageContext(image.size);
85 [image drawAtPoint:CGPointMake(0,0)];
103 CGContextRef context = UIGraphicsGetCurrentContext();
104 CGContextSetLineWidth(context, tickness);
105 CGContextSetStrokeColorWithColor(context, [[UIColor redColor] CGColor]);
106 CGContextMoveToPoint(context, ipo.
get_u(), ipo.
get_v());
107 CGContextAddLineToPoint(context, ip1.
get_u(), ip1.
get_v());
108 CGContextStrokePath(context);
112 context = UIGraphicsGetCurrentContext();
113 CGContextSetLineWidth(context, tickness);
114 CGContextSetStrokeColorWithColor(context, [[UIColor greenColor] CGColor]);
115 CGContextMoveToPoint(context, ipo.
get_u(), ipo.
get_v());
116 CGContextAddLineToPoint(context, ip1.
get_u(), ip1.
get_v());
117 CGContextStrokePath(context);
121 context = UIGraphicsGetCurrentContext();
122 CGContextSetLineWidth(context, tickness);
123 CGContextSetStrokeColorWithColor(context, [[UIColor blueColor] CGColor]);
124 CGContextMoveToPoint(context, ipo.
get_u(), ipo.
get_v());
125 CGContextAddLineToPoint(context, ip1.
get_u(), ip1.
get_v());
126 CGContextStrokePath(context);
129 UIImage *retImage = UIGraphicsGetImageFromCurrentImageContext();
132 UIGraphicsEndImageContext();
Implementation of an homogeneous matrix and operations on such kind of matrices.
static void convertPoint(const vpCameraParameters &cam, const double &x, const double &y, double &u, double &v)
Point coordinates conversion from normalized coordinates in meter to pixel coordinates ...
Class that defines what is a point.
Generic class defining intrinsic camera parameters.
Class that defines a 2D point in an image. This class is useful for image processing and stores only ...