Value meaning of M34 field in Catransform3d

Source: Internet
Author: User

Reprinted from: Http://zhidao.baidu.com/link?url= olvqogokibmaxkgqisoltzlitlpvreoosrmny3yeba1wb6-b3ktuklrxmv0to3y4s1rvjs8ie-0ekscfmzkn5v1mo2nmoszfm33l9r7-_kg

I can't explain it very clearly, said the wrong other children's shoes:

The structure of the transform is as follows:
struct CATRANSFORM3D
{
CGFloat M11, M12, M13, M14;
CGFloat M21, M22, M23, M24;
CGFloat M31, M32, M33, M34;
CGFloat M41, M42, M43, M44;
};

The first thing to do is to achieve a view (layer) perspective (which is nearly large and small) by setting M34:

Catransform3d rotationandperspectivetransform = catransform3didentity;
ROTATIONANDPERSPECTIVETRANSFORM.M34 = 1.0/-500;

M34 is responsible for the z-direction of the translation (move), m34= -1/d, the default value is 0, that is, D infinity, which means that the layer in projection plane (projection surface) and layer in the world The coordinate coincide.

d The smaller the perspective effect, the more obvious.

The so-called D is the distance from the eye (Observer) to the projection plane.

Value meaning of M34 field in Catransform3d

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.