0

This may seem like such a newbie question, but i want to draw a line From Two Points for Specific Height

i've Done like This

  UIBezierPath *path = [UIBezierPath bezierPath];
    [path moveToPoint:CGPointMake(point1.x,point1.y)];
    [path addLineToPoint:CGPointMake(point2.x,point2.y)];

    CAShapeLayer *shapeLayer = [CAShapeLayer layer];
    shapeLayer.path = [path CGPath];
    shapeLayer.strokeColor = [[UIColor greenColor] CGColor];
    shapeLayer.lineWidth = 0.5;
    shapeLayer.fillColor = [[UIColor clearColor] CGColor];

    [view.layer addSublayer:shapeLayer];

Edit :

enter image description here

for example , See above image : i want to extend vertical line (lower lips to upper lips point) but i have only two points 1. lower lips point and 2. mouth center point . . .

Naman Vaishnav
  • 1,069
  • 1
  • 13
  • 24
  • 1
    Can you add some picture of what you want to achieve? – channi Jan 18 '17 at 07:19
  • Possible duplicate of [how do you draw a line programmatically from a view controller?](http://stackoverflow.com/questions/16846413/how-do-you-draw-a-line-programmatically-from-a-view-controller) – mattsson Jan 18 '17 at 07:27

0 Answers0