CDXBnds Region Functions

The CDXBnds region functions are useful for testing whether the bounds are empty or NULL, or whether they intersect other bounds, as well as for normalizing bounds or creating bounds from unions and intersections of objects.

Member Functions

BoundsAreEmpty Tests whether the bounds are empty.
BoundsAreNull Tests whether the bounds are NULL.
IntersectBounds( const CDXB_C& Bounds1, const CDXB_C& Bounds2 ) Determines whether the two specified bounds intersect.
IntersectBounds( const CDXB_C& OtherBounds ) Determines whether the two specified bounds intersect.
NormalizeBounds Sets all of the minimum bounds less than or equal to the maximum bounds.
TestIntersect Tests whether the specified bounds intersect the data object.
UnionBounds Creates a union of the two specified bounds and assigns the result to the data object.

CDXBnds::BoundsAreEmpty

CDXBnds Class

Tests whether the bounds are empty.

Syntax

BOOL BoundsAreEmpty(void) const;

Return Value

Returns TRUE if the the maximum bound was less than or equal to the minimum bound along one of the dimensions. Returns FALSE if the data object has a positive size along all dimensions.

CDXBnds::BoundsAreNull

CDXBnds Class

Tests whether the bounds are NULL.

Syntax

BOOL BoundsAreNull(void) const;

Return Value

Returns TRUE if all the minimum/maximum values equal zero. Returns FALSE if one or more minimum/maximum values are not zero.

CDXBnds::IntersectBounds( const CDXB_C& Bounds1, const CDXB_C& Bounds2 )

CDXBnds Class

Determines whether the two specified bounds intersect.

Syntax

BOOL IntersectBounds(
	const CDXB_C &Bounds1,
	const CDXB_C &Bounds2
);

Parameters

Bounds1
[in] First bounds to use.
Bounds2
[in] Second bounds to use.

Return Value

Returns TRUE if the objects intersect or FALSE if they do not intersect.

CDXBnds::IntersectBounds( const CDXB_C& OtherBounds )

CDXBnds Class

Determines whether the two specified bounds intersect.

Syntax

BOOL IntersectBounds(
	const CDXB_C &OtherBounds
);

Parameters

OtherBounds
[in] Bounds to intersect with the data object.

Return Value

Returns TRUE if the objects intersect or FALSE if they do not intersect.

CDXBnds::NormalizeBounds

CDXBnds Class

Makes all of the minimum bounds less than or equal to the maximum bounds.

Syntax

void NormalizeBounds(void);

Return Value

No return value.

Remarks

This function exchanges any bounds' minimum/maximum values to make sure that the minimum value is less than or equal to the maximum value along each dimension.

CDXBnds::TestIntersect

CDXBnds Class

Tests whether the specified bounds intersect the data object.

Syntax

BOOL TestIntersect(
	const CDXB_C &Other
) const;

Parameters

Other
[in] Object to test.

Return Value

Returns TRUE if the objects intersect. Returns FALSE if they do not intersect.

CDXBnds::UnionBounds

CDXBnds Class

Creates a union of the two specified bounds and assigns the result to the data object.

Syntax

void UnionBounds(
	const CDXB_C &Bounds1,
	const CDXB_C &Bounds2
);

Parameters

Bounds1
[in] First bounds to create a union from.
Bounds2
[in] Second bounds to create a union from.

Return Value

No return value.


Top of Page Top of Page
© 2000 Microsoft and/or its suppliers. All rights reserved. Terms of Use.