• CGAffineTransform的使用


    typedef struct CGAffineTransform CGAffineTransform;

    struct CGAffineTransform {

      CGFloat a, b, c, d;

      CGFloat tx, ty;

    };

     const CGAffineTransform CGAffineTransformIdentity;

     

    CGAffineTransform CGAffineTransformMake(CGFloat a, CGFloat b,

      CGFloat c, CGFloat d, CGFloat tx, CGFloat ty);

     

    CGAffineTransform CGAffineTransformMakeTranslation(CGFloat tx,

      CGFloat ty) ;

    //大小变化

    CGAffineTransform CGAffineTransformMakeScale(CGFloat sx, CGFloat sy);

    //旋转

    CGAffineTransform CGAffineTransformMakeRotation(CGFloat angle);

     

    bool CGAffineTransformIsIdentity(CGAffineTransform t);

     

    CGAffineTransform CGAffineTransformTranslate(CGAffineTransform t,

      CGFloat tx, CGFloat ty);

    //在t的基础上放大变化

    CGAffineTransform CGAffineTransformScale(CGAffineTransform t,

      CGFloat sx, CGFloat sy) ;

     

    CGAffineTransform CGAffineTransformInvert(CGAffineTransform t);

     

    CGAffineTransform CGAffineTransformConcat(CGAffineTransform t1,

      CGAffineTransform t2);

     

    bool CGAffineTransformEqualToTransform(CGAffineTransform t1,

      CGAffineTransform t2);

     

    CGPoint CGPointApplyAffineTransform(CGPoint point,

      CGAffineTransform t);

     

    GSize CGSizeApplyAffineTransform(CGSize size, CGAffineTransform t);

     

    CGRect CGRectApplyAffineTransform(CGRect rect, CGAffineTransform t);

     

     

     

     

     

     

     

  • 相关阅读:
    c#,简单的冒泡排序
    uwp,c#,listView与gridView列表控件进阶
    使用gensim之KeyedVectors操作词向量模型
    python时间戳
    通过Python查找目录下含有指定字符串的所有文件
    聚类之DBSCAN
    使用pyhanlp进行分词
    将Python对象和变量保存在本地
    通过selenium进行博客备份
    matplotlib颜色代码
  • 原文地址:https://www.cnblogs.com/qzp2014/p/4269826.html
Copyright © 2020-2023  润新知