The set of four homogeneous coordinates x, y, z, and w that represent the position of the
Pointwithin 3DLDF's global coordinate system.
The set of four homogeneous coordinates x, y, z, and w that represent the position of the projection of the
Pointonto a two-dimensional plane for output. The x and y values are used in the MetaPost code written toout_stream. The z value is used in the hidden surface algorithm (which is currently rather primitive and doesn't work very well. see Surface Hiding). The w value can be != 1 , depending on the projection used; the perspective projection is non-affine, so w can take on other values.
A set of four homogeneous coordinates x, y, z, and w.
user_coordinatescurrently has no function. It is intended for use in user-defined coordinate systems. For example, a coordinate system could be defined with respect to a plane surface that isn't parallel to one of the major planes. Such a coordinate system would be convenient for drawing on the plane. ATransformwould make it possible to convert betweenuser_coordinatesandworld_coordinates.
A set of four homogeneous coordinates x, y, z, and w.
view_coordinatescurrently has no function. It may be useful for displaying multiple views in an interactive graphical user interface, or for some other purpose.
Contains the product of the transformations applied to the
Point. Whenapply_transform()is called for thePoint, directly or indirectly, theworld_coordinatesare updated andtransformis reset to the identityTransform. See Point Reference; Applying Transformations.
Returns
on_free_store. This should only betrueif thePointwas dynamically allocated on the free store.Pointsshould only ever be dynamically allocated bycreate_new<Point>(), which usesset_on_free_store()to seton_free_storetotrue. See Point Reference; Constructors and Setting Functions, and Point Reference; Modifying.
Used to tell
Point::output()what MetaPost drawing command (drawdot()orundrawdot()) to write toout_streamwhen outputting aPoint.When
drawdot()orundrawdot()is called on aPoint, thePointis copied and put onto thePicture, which was passed todrawdot()orundrawdot()as an argument (current_pictureby default).drawdot_valueis either set toShape::DRAWDOTorShape::UNDRAWDOTon the copy;this->drawdotis not set.
Used to tell
Point::output()what string to write toout_streamfor the color when outputting aPoint.
Used to tell
Point::output()what string to write toout_streamfor the pen when outputting aPoint.
A set of 6
realvalues indicating the maximum and minumum x, y, and z-coordinates of thePoint. Used for determining whether aPointis projectable with the parameters of a particular invocation ofPicture::output(). See Picture Reference; Outputting.Obviously, the maxima and minima will always be the same for a
Point, namely the x, y, and z-coordinates. However,set_extremes()andget_extremes(), the functions that accessprojective_extremes, are pure virtual functions inclass Shape, so thePointversions must be consistent with the versions for other types derived fromShape.
trueby default. Set tofalsebysuppress_output(), which is called on aShapebyPicture::output(), if theShapeis not projectable. See Picture Reference; Outputting.
The unit of measurement for all distances within a
Picture,"cm"(for centimeters) by default. The x and y-coordinates of the projectedPointsare always followed bymeasurement_unitswhen they're written toout_stream. Unlike Metafont, units of measurement cannot be indicated for individual coordinates. Nor canmeasurement_unitbe changed within aPicture.When I write an input routine, I plan to make it behave the way Metafont does, however, 3DLDF will probably also convert all of the input values to a standard unit, as Metafont does.
Default values for the y and z-coordinate of
Points, when the x-coordinate, or the x and y-coordinates only are specified. Both are 0 by default.These values only used in the constructor and setting function taking one required
realvalue (for the x-coordinate), and two optionalrealvalues (for the y and z-coordinates). They are not used when aPointis declared using the default constructor with no arguments. In this case, the x, y, and z-coordinates will all be 0. See Point Reference; Constructors and Setting Functions.Point A(1); A.show("A:"); -| A: (1, 0, 0); CURR_Y = 5; A.set(2); A.show("A:"); -| A: (2, 5, 0); CURR_Z = 12; Point B(3); B.show("B:"); -| B: (3, 5, 12); Point C; C.show("C:"); -| C: (0, 0, 0);