AGX Dynamics 2.42.1.1
Loading...
Searching...
No Matches
RaytraceShapeInstance.h
Go to the documentation of this file.
1/*
2Copyright 2007-2025. Algoryx Simulation AB.
3
4All AGX source code, intellectual property, documentation, sample code,
5tutorials, scene files and technical white papers, are copyrighted, proprietary
6and confidential material of Algoryx Simulation AB. You may not download, read,
7store, distribute, publish, copy or otherwise disseminate, use or expose this
8material unless having a written signed agreement with Algoryx Simulation AB, or having been
9advised so by Algoryx Simulation AB for a time limited evaluation, or having purchased a
10valid commercial license from Algoryx Simulation AB.
11
12Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13from using this software, unless otherwise stated in written agreements with
14Algoryx Simulation AB.
15*/
16#pragma once
18
19namespace agxSensor
20{
27 {
35 static RtShapeInstance create( RtSceneRef scene, RtShapeRef shape, RtInstanceData* data );
36
40 bool isValid() const;
41
48 void setTransform( const agx::AffineMatrix4x4& agxTransform,
49 agx::Vec3 scale = agx::Vec3( 1 ) );
50
51 RtShapeInstanceHandleRef handle{ nullptr };
52 RtInstanceDataObserver data{ nullptr };
53 RtShapeHandleRef shape{ nullptr };
54 };
55
56 inline bool RtShapeInstance::isValid() const
57 {
58 return handle != nullptr &&
59 shape != nullptr;
60 }
61}
#define AGXSENSOR_EXPORT
The agxSensor namespace contains components to model real-time sensors connected to the physics of AG...
std::shared_ptr< RtShape > RtShapeRef
RtShapeRef RtShapeHandleRef
std::shared_ptr< RtShapeInstanceHandle > RtShapeInstanceHandleRef
std::shared_ptr< RtScene > RtSceneRef
Raytrace shape instance data with a handle to the dito on the GPU, data and shape (ref-counting so th...
RtShapeInstanceHandleRef handle
void setTransform(const agx::AffineMatrix4x4 &agxTransform, agx::Vec3 scale=agx::Vec3(1))
Set/update transform and/or scale of this shape instance in the raytrace environment.
static RtShapeInstance create(RtSceneRef scene, RtShapeRef shape, RtInstanceData *data)
Create given scene and shape.