The Vish Visualization Shell 0.3
Vish
Public Member Functions | List of all members
Wizt::TransformOperator::Functor Struct Reference
Inheritance diagram for Wizt::TransformOperator::Functor:
MemCore::ReferenceBase< Functor >

Public Member Functions

virtual bool begin (VRenderContext &Context) const
 Start the transformation operation, given some rendering context.
 
glsl getShaderFunctions (VRenderContext &Context) const
 
virtual glsl myShaderFunctions (VRenderContext &Context) const
 
- Public Member Functions inherited from MemCore::ReferenceBase< Functor >
auto getObjectCountID () const noexcept
 Get a unique ID for this object in the given domain.
 
bool isIdentical (const WeakPtr< Functor, Functor > &PossibleSelf) const noexcept
 Check if this object is identical to the one used by the given pointer.
 
void mkAutoDestructive ()
 Marks this object as being automatically destructed, e.g.
 
refcount_t refcount () const noexcept
 The strong reference count.
 
 ReferenceBase (Functor *that) noexcept
 Constructor, initializes reference counter to zero.
 
const auto & self () const
 Return weak pointer to the object self.
 
refcount_t wrefcount () const noexcept
 The weak reference count.
 

Additional Inherited Members

- Public Types inherited from MemCore::ReferenceBase< Functor >
using reference_domain_t = Functor
 The type of the base class.
 
using SelfPtr_t = WeakPtr< Functor, Functor >
 Type for a pointer to this object itself.
 
- Protected Member Functions inherited from MemCore::ReferenceBase< Functor >
virtual void extremeUnction ()
 A virtual function that will be called just before the object is destroyed.
 
ReferenceBaseoperator= (const ReferenceBase &R)
 Protected assignment operator (should not be called).
 
void suicide ()
 Delete this.
 
virtual ~ReferenceBase ()
 Virtual destructor.
 

Member Function Documentation

◆ begin()

bool Wizt::TransformOperator::Functor::begin ( VRenderContext Context) const
virtual

Start the transformation operation, given some rendering context.

The function may return false to indicate that the requested transformation is not possible. The calling object will then abort rendering.

◆ getShaderFunctions()

string Wizt::TransformOperator::Functor::getShaderFunctions ( VRenderContext Context) const
               Get a definition of three shader functions of the following signature:
vec4 vish_transform_vertex_WorldToEye(in RelativeVertex theVertex);
vec4 vish_transform_vertex_EyeToScreen(vec4 theVertex_in_EyeSpace);
vec3 vish_transform_normal_WorldToEye(vec3 TheNormal);

as based on the myShaderFunctions() virtual function, plus it includes the getDefaultShaderFunctions() code and the getConvenienceShaderFunctions() code.

◆ myShaderFunctions()

string Wizt::TransformOperator::Functor::myShaderFunctions ( VRenderContext Context) const
virtual
               Must define three shader functions of the following signature:
vec4 vish_transform_vertex_WorldToEye(vec4 theVertex, vec3 TranslationVector);
vec4 vish_transform_vertex_EyeToScreen(vec4 theVertex_in_EyeSpace);
vec3 vish_transform_normal_WorldToEye(vec3 TheNormal);

These function may call the shader functions as predefined in getDefaultShaderFunctions(VRenderContext&Context);