1. An information processing apparatus comprising: one or more memories that store a set of instructions; and one or more processors that execute the instructions to: acquire a captured image of a measurement target object on which a projection pattern is projected, the projection pattern being formed by arranging a plurality of line sets at intervals longer than a predetermined value, each of the plurality of line sets having lines arranged at intervals shorter than the predetermined value; detect the lines in the projection pattern from the image; determine the line sets from detected lines; identify to which one of the lines in the projection pattern a detected line corresponds, based on a result; calculate a distance from a predetermined reference coordinate to a position on a plane of the measurement target object on which a detected line is projected, based on a position in the image of the detected line and a position in the projection pattern of an identified line; and calculate a plane direction of a plane of the measurement target object on which a line set is projected, based on a distance calculated at a first point on a first line among the detected lines, a distance calculated at a second point on the first line, and a distance calculated at a third point on a second line belonging to a same line set to which the first line belongs to.