vsg  1.1.0
VulkanSceneGraph library
Public Types | Public Member Functions | Protected Attributes | List of all members
vsg::Intersector Class Referenceabstract

#include <Intersector.h>

Inheritance diagram for vsg::Intersector:
Inheritance graph
[legend]
Collaboration diagram for vsg::Intersector:
Collaboration graph
[legend]

Public Types

using NodePath = std::vector< const Node * >
 
using ArrayStateStack = std::vector< ref_ptr< ArrayState > >
 

Public Member Functions

 Intersector (ref_ptr< ArrayState > initialArrayState={})
 
void apply (const Node &node) override
 
void apply (const StateGroup &stategroup) override
 
void apply (const Transform &transform) override
 
void apply (const LOD &lod) override
 
void apply (const PagedLOD &plod) override
 
void apply (const CullNode &cn) override
 
void apply (const CullGroup &cn) override
 
void apply (const DepthSorted &cn) override
 
void apply (const VertexDraw &vid) override
 
void apply (const VertexIndexDraw &vid) override
 
void apply (const Geometry &geometry) override
 
void apply (const BindVertexBuffers &bvb) override
 
void apply (const BindIndexBuffer &bib) override
 
void apply (const Draw &draw) override
 
void apply (const DrawIndexed &drawIndexed) override
 
void apply (const BufferInfo &bufferInfo) override
 
void apply (const ushortArray &array) override
 
void apply (const uintArray &array) override
 
virtual void pushTransform (const Transform &transform)=0
 clone and transform this Intersector to provide a new Intersector in local coordinates
 
virtual void popTransform ()=0
 
virtual bool intersects (const dsphere &sphere)=0
 check for intersection with sphere
 
virtual bool intersectDraw (uint32_t firstVertex, uint32_t vertexCount, uint32_t firstInstance, uint32_t instanceCount)=0
 intersect with a vkCmdDraw primitive
 
virtual bool intersectDrawIndexed (uint32_t firstIndex, uint32_t indexCount, uint32_t firstInstance, uint32_t instanceCount)=0
 intersect with a vkCmdDrawIndexed primitive
 
std::vector< dmat4 > & localToWorldStack ()
 get the current local to world matrix stack
 
std::vector< dmat4 > & worldToLocalStack ()
 get the current world to local matrix stack
 
- Public Member Functions inherited from vsg::Inherit< ConstVisitor, Intersector >
 Inherit (Args &&... args)
 
std::size_t sizeofObject () const noexcept override
 
const char * className () const noexcept override
 
const std::type_info & type_info () const noexcept override
 
bool is_compatible (const std::type_info &type) const noexcept override
 
int compare (const Object &rhs) const override
 
void accept (Visitor &visitor) override
 
void accept (ConstVisitor &visitor) const override
 
void accept (RecordTraversal &visitor) const override
 
- Public Member Functions inherited from vsg::ConstVisitor
virtual void apply (const Object &)
 
virtual void apply (const Objects &)
 
virtual void apply (const External &)
 
virtual void apply (const Data &)
 
virtual void apply (const stringValue &)
 
virtual void apply (const wstringValue &)
 
virtual void apply (const boolValue &)
 
virtual void apply (const intValue &)
 
virtual void apply (const uintValue &)
 
virtual void apply (const floatValue &)
 
virtual void apply (const doubleValue &)
 
virtual void apply (const vec2Value &)
 
virtual void apply (const vec3Value &)
 
virtual void apply (const vec4Value &)
 
virtual void apply (const dvec2Value &)
 
virtual void apply (const dvec3Value &)
 
virtual void apply (const dvec4Value &)
 
virtual void apply (const bvec2Value &)
 
virtual void apply (const bvec3Value &)
 
virtual void apply (const bvec4Value &)
 
virtual void apply (const ubvec2Value &)
 
virtual void apply (const ubvec3Value &)
 
virtual void apply (const ubvec4Value &)
 
virtual void apply (const svec2Value &)
 
virtual void apply (const svec3Value &)
 
virtual void apply (const svec4Value &)
 
virtual void apply (const usvec2Value &)
 
virtual void apply (const usvec3Value &)
 
virtual void apply (const usvec4Value &)
 
virtual void apply (const ivec2Value &)
 
virtual void apply (const ivec3Value &)
 
virtual void apply (const ivec4Value &)
 
virtual void apply (const uivec2Value &)
 
virtual void apply (const uivec3Value &)
 
virtual void apply (const uivec4Value &)
 
virtual void apply (const byteArray &)
 
virtual void apply (const ubyteArray &)
 
virtual void apply (const shortArray &)
 
virtual void apply (const intArray &)
 
virtual void apply (const floatArray &)
 
virtual void apply (const doubleArray &)
 
virtual void apply (const vec2Array &)
 
virtual void apply (const vec3Array &)
 
virtual void apply (const vec4Array &)
 
virtual void apply (const dvec2Array &)
 
virtual void apply (const dvec3Array &)
 
virtual void apply (const dvec4Array &)
 
virtual void apply (const bvec2Array &)
 
virtual void apply (const bvec3Array &)
 
virtual void apply (const bvec4Array &)
 
virtual void apply (const svec2Array &)
 
virtual void apply (const svec3Array &)
 
virtual void apply (const svec4Array &)
 
virtual void apply (const ivec2Array &)
 
virtual void apply (const ivec3Array &)
 
virtual void apply (const ivec4Array &)
 
virtual void apply (const ubvec2Array &)
 
virtual void apply (const ubvec3Array &)
 
virtual void apply (const ubvec4Array &)
 
virtual void apply (const usvec2Array &)
 
virtual void apply (const usvec3Array &)
 
virtual void apply (const usvec4Array &)
 
virtual void apply (const uivec2Array &)
 
virtual void apply (const uivec3Array &)
 
virtual void apply (const uivec4Array &)
 
virtual void apply (const mat4Array &)
 
virtual void apply (const dmat4Array &)
 
virtual void apply (const block64Array &)
 
virtual void apply (const block128Array &)
 
virtual void apply (const ubyteArray2D &)
 
virtual void apply (const ushortArray2D &)
 
virtual void apply (const uintArray2D &)
 
virtual void apply (const floatArray2D &)
 
virtual void apply (const doubleArray2D &)
 
virtual void apply (const vec2Array2D &)
 
virtual void apply (const vec3Array2D &)
 
virtual void apply (const vec4Array2D &)
 
virtual void apply (const dvec2Array2D &)
 
virtual void apply (const dvec3Array2D &)
 
virtual void apply (const dvec4Array2D &)
 
virtual void apply (const bvec2Array2D &)
 
virtual void apply (const bvec3Array2D &)
 
virtual void apply (const bvec4Array2D &)
 
virtual void apply (const svec2Array2D &)
 
virtual void apply (const svec3Array2D &)
 
virtual void apply (const svec4Array2D &)
 
virtual void apply (const ivec2Array2D &)
 
virtual void apply (const ivec3Array2D &)
 
virtual void apply (const ivec4Array2D &)
 
virtual void apply (const ubvec2Array2D &)
 
virtual void apply (const ubvec3Array2D &)
 
virtual void apply (const ubvec4Array2D &)
 
virtual void apply (const usvec2Array2D &)
 
virtual void apply (const usvec3Array2D &)
 
virtual void apply (const usvec4Array2D &)
 
virtual void apply (const uivec2Array2D &)
 
virtual void apply (const uivec3Array2D &)
 
virtual void apply (const uivec4Array2D &)
 
virtual void apply (const block64Array2D &)
 
virtual void apply (const block128Array2D &)
 
virtual void apply (const ubyteArray3D &)
 
virtual void apply (const ushortArray3D &)
 
virtual void apply (const uintArray3D &)
 
virtual void apply (const floatArray3D &)
 
virtual void apply (const doubleArray3D &)
 
virtual void apply (const vec2Array3D &)
 
virtual void apply (const vec3Array3D &)
 
virtual void apply (const vec4Array3D &)
 
virtual void apply (const dvec2Array3D &)
 
virtual void apply (const dvec3Array3D &)
 
virtual void apply (const dvec4Array3D &)
 
virtual void apply (const ubvec2Array3D &)
 
virtual void apply (const ubvec3Array3D &)
 
virtual void apply (const ubvec4Array3D &)
 
virtual void apply (const block64Array3D &)
 
virtual void apply (const block128Array3D &)
 
virtual void apply (const Compilable &)
 
virtual void apply (const Commands &)
 
virtual void apply (const Group &)
 
virtual void apply (const QuadGroup &)
 
virtual void apply (const MatrixTransform &)
 
virtual void apply (const Bin &)
 
virtual void apply (const Switch &)
 
virtual void apply (const Light &)
 
virtual void apply (const AmbientLight &)
 
virtual void apply (const DirectionalLight &)
 
virtual void apply (const PointLight &)
 
virtual void apply (const SpotLight &)
 
virtual void apply (const Text &)
 
virtual void apply (const TextGroup &)
 
virtual void apply (const TextTechnique &)
 
virtual void apply (const TextLayout &)
 
virtual void apply (const Command &)
 
virtual void apply (const StateCommand &)
 
virtual void apply (const StateSwitch &)
 
virtual void apply (const CommandBuffer &)
 
virtual void apply (const RenderPass &)
 
virtual void apply (const BindDescriptorSet &)
 
virtual void apply (const BindDescriptorSets &)
 
virtual void apply (const BindViewDescriptorSets &)
 
virtual void apply (const Descriptor &)
 
virtual void apply (const DescriptorBuffer &)
 
virtual void apply (const DescriptorImage &)
 
virtual void apply (const DescriptorSet &)
 
virtual void apply (const BindComputePipeline &)
 
virtual void apply (const BindGraphicsPipeline &)
 
virtual void apply (const BindRayTracingPipeline &)
 
virtual void apply (const GraphicsPipeline &)
 
virtual void apply (const ComputePipeline &)
 
virtual void apply (const RayTracingPipeline &)
 
virtual void apply (const GraphicsPipelineState &)
 
virtual void apply (const ShaderStage &)
 
virtual void apply (const VertexInputState &)
 
virtual void apply (const InputAssemblyState &)
 
virtual void apply (const TessellationState &)
 
virtual void apply (const ViewportState &)
 
virtual void apply (const RasterizationState &)
 
virtual void apply (const MultisampleState &)
 
virtual void apply (const DepthStencilState &)
 
virtual void apply (const ColorBlendState &)
 
virtual void apply (const DynamicState &)
 
virtual void apply (const ResourceHints &)
 
virtual void apply (const ClearAttachments &)
 
virtual void apply (const ClearColorImage &)
 
virtual void apply (const ClearDepthStencilImage &)
 
virtual void apply (const QueryPool &)
 
virtual void apply (const ResetQueryPool &)
 
virtual void apply (const BeginQuery &)
 
virtual void apply (const EndQuery &)
 
virtual void apply (const WriteTimestamp &)
 
virtual void apply (const CopyQueryPoolResults &)
 
virtual void apply (const DrawMeshTasks &)
 
virtual void apply (const DrawMeshTasksIndirect &)
 
virtual void apply (const DrawMeshTasksIndirectCount &)
 
virtual void apply (const UIEvent &)
 
virtual void apply (const WindowEvent &)
 
virtual void apply (const ExposeWindowEvent &)
 
virtual void apply (const ConfigureWindowEvent &)
 
virtual void apply (const CloseWindowEvent &)
 
virtual void apply (const FocusInEvent &)
 
virtual void apply (const FocusOutEvent &)
 
virtual void apply (const KeyEvent &)
 
virtual void apply (const KeyPressEvent &)
 
virtual void apply (const KeyReleaseEvent &)
 
virtual void apply (const PointerEvent &)
 
virtual void apply (const ButtonPressEvent &)
 
virtual void apply (const ButtonReleaseEvent &)
 
virtual void apply (const MoveEvent &)
 
virtual void apply (const TouchEvent &)
 
virtual void apply (const TouchDownEvent &)
 
virtual void apply (const TouchUpEvent &)
 
virtual void apply (const TouchMoveEvent &)
 
virtual void apply (const ScrollWheelEvent &)
 
virtual void apply (const TerminateEvent &)
 
virtual void apply (const FrameEvent &)
 
virtual void apply (const AnimationPath &)
 
virtual void apply (const ShaderCompileSettings &)
 
virtual void apply (const Camera &)
 
virtual void apply (const CommandGraph &)
 
virtual void apply (const RenderGraph &)
 
virtual void apply (const View &)
 
virtual void apply (const Viewer &)
 
virtual void apply (const FrameStamp &)
 
- Public Member Functions inherited from vsg::Object
 Object (const Object &)
 
Objectoperator= (const Object &)
 
template<class T >
T * cast ()
 
template<class T >
const T * cast () const
 
virtual void traverse (Visitor &)
 
virtual void traverse (ConstVisitor &) const
 
virtual void traverse (RecordTraversal &) const
 
virtual void read (Input &input)
 
virtual void write (Output &output) const
 
void ref () const noexcept
 
void unref () const noexcept
 
void unref_nodelete () const noexcept
 
unsigned int referenceCount () const noexcept
 
template<typename T >
void setValue (const std::string &key, const T &value)
 
void setValue (const std::string &key, const char *value)
 specialization of setValue to handle passing C strings
 
template<typename T >
bool getValue (const std::string &key, T &value) const
 get specified value type, return false if value associated with key is not assigned or is not the correct type
 
void setObject (const std::string &key, ref_ptr< Object > object)
 assign an Object associated with key
 
ObjectgetObject (const std::string &key)
 get Object pointer associated with key, return nullptr if no object associated with key has been assigned
 
const ObjectgetObject (const std::string &key) const
 get const Object pointer associated with key, return nullptr if no object associated with key has been assigned
 
template<class T >
T * getObject (const std::string &key)
 get object pointer of specified type associated with key, return nullptr if no object associated with key has been assigned
 
template<class T >
const T * getObject (const std::string &key) const
 get const object pointer of specified type associated with key, return nullptr if no object associated with key has been assigned
 
ref_ptr< ObjectgetRefObject (const std::string &key)
 get ref_ptr<Object> associated with key, return nullptr if no object associated with key has been assigned
 
ref_ptr< const ObjectgetRefObject (const std::string &key) const
 get ref_ptr<const Object> pointer associated with key, return nullptr if no object associated with key has been assigned
 
template<class T >
ref_ptr< T > getRefObject (const std::string &key)
 get ref_ptr<T> of specified type associated with key, return nullptr if no object associated with key has been assigned
 
template<class T >
const ref_ptr< const T > getRefObject (const std::string &key) const
 get ref_ptr<const T> of specified type associated with key, return nullptr if no object associated with key has been assigned
 
void removeObject (const std::string &key)
 remove meta object or value associated with key
 
AuxiliarygetOrCreateAuxiliary ()
 
AuxiliarygetAuxiliary ()
 
const AuxiliarygetAuxiliary () const
 

Protected Attributes

ArrayStateStack arrayStateStack
 
ref_ptr< const ushortArray > ushort_indices
 
ref_ptr< const uintArray > uint_indices
 
NodePath _nodePath
 

Additional Inherited Members

- Static Public Member Functions inherited from vsg::Inherit< ConstVisitor, Intersector >
static ref_ptr< Intersectorcreate (Args &&... args)
 
static ref_ptr< Intersectorcreate_if (bool flag, Args &&... args)
 
- Static Public Member Functions inherited from vsg::Object
static ref_ptr< Objectcreate ()
 
static ref_ptr< Objectcreate_if (bool flag)
 
static void * operator new (std::size_t count)
 provide new and delete to enable custom memory management via the vsg::Allocator singleton, using the MEMORY_AFFINTY_OBJECTS
 
static void operator delete (void *ptr)
 
- Public Attributes inherited from vsg::ConstVisitor
Mask traversalMask = MASK_ALL
 
Mask overrideMask = MASK_OFF
 
- Protected Member Functions inherited from vsg::Object
virtual void _attemptDelete () const
 
void setAuxiliary (Auxiliary *auxiliary)
 

Detailed Description

Intersector is a base class for intersecting the scene graph. The LineSegmentIntersector subclass adds support for line segment intersections.


The documentation for this class was generated from the following file: