Pixel.HitProps Interface

Describes a subset of HitDetailProps computed from a Pixel.Data, suitable for constructing a HitDetail. For example, the following function creates a HitDetail from a Pixel.Data and other hit information:

 function makeHitDetail(pixel: Pixel.Data, viewport: ScreenViewport, testPoint: Point3d, hitSource: HitSource, hitPoint: Point3d, distXY: number): HitDetail {
   return new HitDetail({
     ...pixel.toHitProps(viewport),
     viewport, testPoint, hitSource, hitPoint, distXY,
   };
 }

@see toHitProps to convert a Pixel.Data to a HitProps.

Properties

Name Type Description
distFraction number The distance in view coordinates between the hit and the near plane.  
geometryClass GeometryClass | undefined The class of the hit geometry.  
modelId string | undefined The Id of the ModelState from which the hit originated.  
path HitPath | undefined Path through which the hit was located.  
priority HitPriority The hit geometry priority/classification.  
sourceId string The source of the geometry.  
subCategoryId string | undefined The SubCategory to which the hit geometry belongs.  

Defined in

Last Updated: 13 November, 2024