ImFusion SDK 4.3
MyCustomGlObject.h
#pragma once
#include <ImFusion/GL/GlObject.h>
class MyCustomGlObject : public ImFusion::GlObject
{
public:
// This function implements the actual rendering code
virtual void draw(const ImFusion::GlView& view) override;
// This function returns the world extent of the rendered object so that the
// view architecture can automatically determine proper scaling etc.
// For now we return a default (empty) extent.
// Return a string ID of this class that can be used for serialization.
virtual std::string typeName() const override { return "MyCustomGlObject"; }
};
Class representing an axis aligned rectangular cuboid in 3D space.
Definition Box.h:27
Abstract base class for an renderable OpenGL object that can be hosted in a GlView.
Definition GlObject.h:23
virtual std::string typeName() const =0
Return unique identifier for this object class used for serialization.
virtual Geometry::AlignedBox bounds() const =0
Get the axis-aligned bounding box of this GlObject in world space.
virtual void draw(const GlView &view)=0
Draw the object in 3D space.
Base class for implementing OpenGL views.
Definition GlView.h:36
Search Tab / S to search, Esc to close