Rhino C++ API
8.14
|
#include <RhinoSdkDisplayEngine_OGL.h>
Public Member Functions | |
CRhinoDisplayEngine_OGL () | |
virtual | ~CRhinoDisplayEngine_OGL () |
int | ActiveStereoProjection () const override |
0 = left, 1 = right... More... | |
void | AddLight (const ON_Light &) override |
bool | CanSaveDepthBuffer () override |
bool | CaptureFrame (const ON_Viewport &viewport) override |
bool | CaptureFrameTo (class CRhOpenGLTexture2D &) |
void | ClearDepthBuffer () override |
void | ClearFrameBuffer (const CRhinoDib *) override |
void | ClearFrameBuffer (const ON_Color &, const ON_Color &, const ON_Color &, const ON_Color &) override |
void | ClearTextureCache () override |
bool | CopyBackBufferFrom (const CRhinoDib &) override |
bool | CopyBackBufferTo (CRhinoDib &) override |
bool | CopyDepthBufferTo (CRhinoDib &, bool=false, bool=false, CRhinoDib *=nullptr) override |
int | DepthBufferBitDepth () override |
int | DepthMode () |
void | Draw2dLines (const ON_2fPoint *points, int count, bool asPolyline, ON_Color strokeColor, float strokeWidth, RhinoDashStyle style, bool xormode) override |
void | DrawBitmap (const CRhinoDib &dib, int left, int top) override |
void | DrawBitmap (const CRhinoDib &dib, int left, int top, int width, int height) |
void | DrawBrepWires (const ON_Brep *brep, const class CDisplayPipelineAttributes *da, int wireDensity, bool edgeAnalysis, CRhinoCacheHandle *cacheHandle) override |
bool | DrawCapturedFrame (const ON_Viewport &destination) override |
bool | DrawCombinedTextures (UINT nT1, UINT nT2, int nCOP, float Scale, ON_Color Color=ON_UNSET_COLOR) |
void | DrawCurve (const ON_Curve &curve, const class CRhinoDisplayPen &pen, CRhinoCacheHandle *cacheHandle) override |
void | DrawDot (const ON_TextDot &dot, bool locationInWorld, ON_Color fillColor, ON_Color textColor, ON_Color borderColor, CRhinoCacheHandle *cache) override |
void | DrawEnvironment () override |
void | DrawExtrusionWires (const ON_Extrusion &extrusion, const class CDisplayPipelineAttributes *da, int wireDensity, bool edgeAnalysis, CRhinoCacheHandle *cacheHandle) override |
void | DrawGroundPlane (const class CDisplayPipelineAttributes &dpa, const class CRhDisplayGroundPlane &groundplane) override |
void | DrawHatch (const ON_Hatch &hatch, const class CRhinoDisplayBrush *fillBrush, const class CRhinoDisplayPen *boundaryPen, CRhinoCacheHandle *cacheHandle) override |
void | DrawHatch (const ON_Hatch &hatch, const ON_HatchPattern *pattern, float strokeWidth, ON_Color hatchColor, ON_Color boundaryColor, CRhinoCacheHandle *cacheHandle) override |
void | DrawLines (const class CLinesDescriptor &) override |
void | DrawMeshes (const ON_Mesh **meshes, int count, bool wires, bool shaded, const CDisplayPipelineAttributes *da, CRhinoCacheHandle *cacheHandle) override |
void | DrawMeshFaces (const ON_Mesh &mesh, const int *faces, int faceCount, const CDisplayPipelineAttributes *da, CRhinoCacheHandle *cacheHandle) override |
void | DrawPointCloud (const ON_PointCloud &cloud, ERhinoPointStyle style, float pixelSize, bool scaleSizeForDpi, ON_Color colorOverride, int indexCount, const unsigned int *indices, CRhinoCacheHandle *cache, int degradeCount) override |
void | DrawPoints (int count, const class CRhPointData *points, CRhinoCacheHandle *) override |
void | DrawPolygon (const ON_3dPoint *points, int count, ON_Color color, bool bFilled) override |
void | DrawPolylines (const CRhinoClippingVertexCollection *lists, int count) override |
void | DrawRoundedRectangle (ON_2fPoint screenCenter, float pixelWidth, float pixelHeight, float cornerRadius, ON_Color strokeColor, float strokeWidth, ON_Color fillColor) override |
void | DrawString (const wchar_t *text, const ON_Color &textColor, const ON_2dPoint &point, bool middle, float fontHeightPixels, const ON_Font *font) override |
void | DrawString (const wchar_t *text, const ON_Xform &xf, const ON_Font *font, const ON_Color &color, ON::TextHorizontalAlignment horizontalAlignment, ON::TextVerticalAlignment verticalAlignment, CRhinoCacheHandle *cache) override |
void | DrawSubD (const class CRhinoSubDDisplay &subd_display, const class CRhinoSubDDisplayAttributes &subd_display_attributes) override |
void | DrawTraceImage (const class CRhTraceImage &traceimage) override |
void | DrawViewportAlignedImage (const class CRhOpenGLTexture &image, bool bProgramInUse) |
void | DrawViewportAlignedQuad (bool bProgramInUse) |
void | DrawWallpaper (const class CRhWallpaper &wallpaper) override |
void | EnableColorWriting (bool=true) override |
void | EnableDepthTesting (bool=true) override |
Depth-Buffered operations & attributes... More... | |
void | EnableDepthWriting (bool=true) override |
void | EnableMeshBuffering (bool on) override |
"State" operations & attributes... More... | |
void | EnableMultiSample (bool bEnable=true) override |
Enables / disables multisampling. More... | |
void | EnableShadowMap (bool bEnable=true) |
unsigned int | ExecutionLevel () const |
void | FlushAll () override |
int | FrameBufferBitDepth () override |
void | FrameBufferChannelDepth (int &, int &, int &, int &) override |
bool | GetBackBuffer (CRhinoDib &) override |
const class CRhFrameCapture * | GetCapturedFrame () const override |
bool | GetDepthBuffer (float *buffer, int left, int top, int width, int height) override |
class CRhDisplayEnginePrivate_OGL * | GetEngineGlPrivate () |
class CRhOpenGLRenderer * | GetFrameBufferObject () |
void | GetGlCameraToClip (float m[16], const ON_Xform *extra) const |
void | GetGlCameraToClipInverse (float m[16], const ON_Xform *extra) const |
void | GetGlClipToScreen (float m[16]) const |
void | GetGlScreenToClip (float m[16]) const |
void | GetGlWorldToCamera (float m[16], bool includeModelTransform, const ON_Xform *extra) const |
void | GetGlWorldToCameraInverse (float m[16], bool includeModelTransform, const ON_Xform *extra) const |
void | GetGlWorldToClip (float m[16], bool includeModelTransform, const ON_Xform *extra) const |
void | GetGlWorldToClipInverse (float m[16], bool includeModelTransform, const ON_Xform *extra) const |
int | GetMultiSampleMode () const override |
void | GetMultiSampleModes (ON_SimpleArray< int > &) const override |
bool | GetOffscreenBufferInfo (HDC dc, int &, int &) override |
HGLRC | GetRenderingContext () const |
bool | HasDepthBuffer () override |
Engine buffers support... More... | |
void | InvalidateCapturedFrame () override |
Caching operations... More... | |
bool | IsAccelerated () const override |
bool | IsPreview (void) const |
bool | IsShadowMapEnabled () |
const CDisplayPipelineAttributes::LinearWorkflow & | LinearWorkflow () const |
int | MaxClipPlanesSupported () const override |
int | MaxDecalsSupported () const override |
int | MaxLightsSupported () const override |
int | MaxObjectMappingsSupported () const override |
int | MaxTextureCoords () const |
int | MaxTextureSize () const |
int | MaxTextureUnits () const |
bool | MeshBufferingEnabled () const override |
bool | PostProcessFrameBuffer () |
ON_UUID | PreviewEnvironmentId (void) const |
void | ProcessLinearWorkflow (const class CRhOpenGLTexture &image, const float gammaExponent) |
int | RenderPass () const |
bool | ResetEngine () override |
bool | RestoreBackBuffer () override |
bool | RestoreDepthBuffer () override |
bool | SaveBackBuffer () override |
bool | SaveDepthBuffer () override |
ECullFaceMode | SetCullFaceMode (ECullFaceMode mode) override |
int | SetDepthMode (int) override |
void | SetIsPreview (bool) |
void | SetLinearWorkflow (const CDisplayPipelineAttributes::LinearWorkflow &lw) |
Linear workflow support. More... | |
bool | SetMultiSampleMode (int) override |
void | SetPreviewEnvironmentId (ON_UUID) |
bool | SetStereoMode (bool) override |
void | SetTextureCoords (int nTex, int stride, const void *) const |
bool | ShowBackBuffer (HDC dc) override |
void | ShutdownEngine () override |
bool | StartEngine () override |
Engine initialization and cleanup operations... More... | |
bool | StopEngine () override |
bool | SupportsMultiSampling () const override |
bool | SupportsShading () const override |
bool | SupportsStencilBuffer () const |
void | TransformShadowMatrix (bool bTransform) |
void | UseHardwareModes (bool=true) |
Specific OpenGL hardware information. More... | |
Public Member Functions inherited from CRhinoDisplayEngine | |
CRhinoDisplayEngine () | |
virtual | ~CRhinoDisplayEngine () |
const ON_Xform & | CameraToClip () const |
const ON_Xform & | CameraToClipInverse () const |
virtual void | ClearClipPlanes () |
void | ClearFrameBuffer (const ON_Color &color) |
void | ClearFrameBuffer (const ON_Color &colorTop, const ON_Color &colorBottom) |
virtual void | ClearLights () |
const ON_SimpleArray< ON_ClippingPlaneInfo > & | ClippingPlanes () const |
ON_2dPoint | ClippingToScreenPoint (const ON_4dPoint &point) const |
int | ClipPlaneCount () const |
virtual bool | CopyBackBufferFrom (HDC pDC) |
virtual bool | CopyBackBufferTo (HDC hDC) |
virtual bool | CopyDepthToBackBuffer () |
virtual int | CreateClipRegion (const ON_Curve &boundary) |
ECullFaceMode | CullFaceMode () const |
virtual void | DestroyClipRegion (int region_id) |
void | DisableCoplanarClippingPlanes (const CRhinoObject *pRhinoObject, ON_SimpleArray< int > &planes_disabled) |
void | DisableCoplanarClippingPlanes (const ON_Plane &plane, ON_SimpleArray< int > &planes_disabled) |
const CDisplayPipelineAttributes * | DisplayAttrs () const |
float | DpiScale () const |
virtual void | DrawBezier (int dim, BOOL32 bIsRational, int order, int cv_stride, const double *cv4d, const CRhCurveAttributes &attrs) |
void | DrawBrepWires (const ON_Brep *brep, const class CDisplayPipelineAttributes *da, int wireDensity, bool edgeAnalysis, const class CRhDisplayPenPrivate *pen, CRhinoCacheHandle *cacheHandle) |
virtual void | DrawConstructionPlane (const ON_3dmConstructionPlane &plane, bool bShowGrid, bool bShowGridAxes, bool bShowZAxis, const ON_Color &grid_thin_color, const ON_Color &grid_thick_color, const ON_Color &grid_xaxis_color, const ON_Color &grid_yaxis_color, const ON_Color &grid_zaxis_color, int grid_thick_line_size, int grid_axis_line_size, int axes_percentage=100, bool bForceBackground=false) |
void | DrawExtrusionWires (const ON_Extrusion &extrusion, const class CDisplayPipelineAttributes *da, int wireDensity, bool edgeAnalysis, const class CRhDisplayPenPrivate *pen, CRhinoCacheHandle *cacheHandle) |
void | DrawHatch (const ON_Hatch &hatch, const class CRhinoDisplayBrush *fillBrush, const class CRhinoDisplayBrush *hatchBrush, const class CRhinoDisplayPen *boundaryPen, CRhinoCacheHandle *cacheHandle) |
virtual void | DrawLine (const ON_3dPoint &from, const ON_3dPoint &to, const ON_Color &color, int thickness, UINT pattern=0xFFFFFFFF) |
void | DrawLineNoClip (const ON_3dPoint &from, const ON_3dPoint &to, const ON_Color &color, float thickness) |
void | DrawMesh (const ON_Mesh &mesh, bool wires, bool shaded, const class CDisplayPipelineAttributes *da, CRhinoCacheHandle *cacheHandle) |
virtual void | DrawMeshes (const ON_Mesh **meshes, int count, bool wires, bool shaded, const class CDisplayPipelineAttributes *da, CRhinoCacheHandle *cacheHandle) |
void | DrawMeshFace (const ON_Mesh &mesh, int faceIndex, const class CDisplayPipelineAttributes *da, CRhinoCacheHandle *cacheHandle) |
virtual void | DrawMeshFaces (const ON_Mesh &mesh, const int *faces, int faceCount, const class CDisplayPipelineAttributes *da, CRhinoCacheHandle *cacheHandle) |
void | DrawMeshFaces (const ON_Mesh &mesh, const ON_SimpleArray< int > &faces, const class CDisplayPipelineAttributes *da, CRhinoCacheHandle *cacheHandle) |
void | DrawPoints (int count, const class CRhPointData *points, const class CRhPointData *forcedOverride, CRhinoCacheHandle *cache, const ON_Xform *ffoTransform, bool precomputedTransform) |
void | DrawPoints (int count, const class CRhPointData *points, CRhinoCacheHandle *cache, const ON_Xform *ffoTransform, bool precomputedTransform) |
virtual void | DrawPoints (int count, const ON_2dPoint *screenPoints, ERhinoPointStyle style, const ON_Color &strokeColor, const ON_Color &fillColor, float diameterPixels, float strokeWidthPixels, float innerDiameterPixels, float rotationRadians, bool autoScaleDpi, CRhinoCacheHandle *cache) |
virtual void | DrawPoints (int count, const ON_3dPoint *points, ERhinoPointStyle style, const ON_Color &strokeColor, const ON_Color &fillColor, float diameter, float strokeWidth, float innerDiameter, float rotationRadians, bool diameterInPixels, bool autoScaleDpi, CRhinoCacheHandle *cache) |
virtual void | DrawPolylines (const class CLinesDescriptor &ld) |
virtual void | DrawPolylines (const class CRhinoClippingVertexCollection *lists, int count)=0 |
virtual void | DrawShadedBrep (const ON_Brep *brep, const class CDisplayPipelineAttributes *da, CRhinoCacheHandle *cacheHandle) |
virtual void | DrawString (const ON_TextContent &text, const ON_Xform &textXform, ON_Color color, CRhinoCacheHandle *cache) |
virtual void | DrawSubD (const class ON_SubD &subd, const class CRhSubDDisplayAttributes *attrs, CRhinoCacheHandle *cacheHandle) |
Do not call - placeholder virtual function in order to improve SubD display without breaking SDK. More... | |
virtual void | DrawSubDComponents (const class ON_SubD &subd, const class ON_SubDComponentPtr *components, size_t componentCount, const class CRhSubDDisplayAttributes *attrs, CRhinoCacheHandle *cacheHandle) |
Do not call - placeholder virtual function in order to improve SubD display without breaking SDK. More... | |
void | DrawSubDWires (const CRhinoSubDDisplay &subd_display, const class CRhinoDisplayPen *boundaryPen, const class CRhinoDisplayPen *smoothInteriorPen, const class CRhinoDisplayPen *creaseInteriorPen, const class CRhinoDisplayPen *nonmanifoldPen) |
void | DrawTechnicalWires (const CRhinoObject &rhinoObject, const ON_Color &color, float borderThickness, float silhouetteThickness, float creaseThickness) |
virtual void | DrawTextRun (const ON_TextRun &run, const ON_Font *font, const ON_Xform &xform, ON_Color color, CRhinoCacheHandle *cache) |
virtual void | DrawWorldAxes (const ON_Color &xaxis_color, const ON_Color &yaxis_color, const ON_Color &zaxis_color, int axes_length, int label_offset, int letter_size) |
virtual bool | EnableClipPlanes (bool bEnable, int plane=-1) |
void | EnableMaterials (bool on) |
void | EnableShadows (bool) |
New for V8 [end]. More... | |
ON_3dPoint | FrustumCenter () const |
const CRhinoDoc * | GeometrySource () const |
Return the document that the pipeline uses to get geometry information from when drawing. More... | |
void | GetCurveAttributes (CRhCurveAttributes &attributes) const |
ON_SimpleArray< ON_PlaneEquation > | GetEnabledClipPlanes (const ON_Xform *xf) const |
void | GetFarPlane (ON_Plane &) const |
virtual const ON_Light * | GetLight (int index) const |
ON_Xform | GetModelViewMatrix () const |
void | GetNearFarPlane (ON_Plane &N, ON_Plane &F) const |
void | GetNearPlane (ON_Plane &) const |
class CRhGLSceneManager * | GetSceneManager (const CRhinoDoc *doc) |
virtual double | GetStereoParallax () const |
virtual double | GetStereoSeparation () const |
const ON_Xform & | InstanceDefinitionTransform () const |
virtual bool | InStereoMode () const |
bool | IsEntireBoxVisible (const ON_BoundingBox &bbox) const |
bool | IsPreview (void) const |
virtual int | LightCount () const |
const CDisplayPipelineAttributes::LinearWorkflow & | LinearWorkflow () const |
int | MaxProceduralCommandsSupported () const |
int | MaxProceduralsSupported () const |
int | MaxProceduralTransformsSupported () const |
const ON_Xform & | ModelTransform () const |
Model transform operations... More... | |
bool | ModelTransformIsIdentity () const |
virtual bool | PopColorWriting () |
virtual void | PopDepthTesting () |
virtual void | PopDepthWriting () |
void | PopModelTransform () |
void | PopModelViewMatrix () |
void | PopProjection () |
ON_UUID | PreviewEnvironmentId (void) const |
virtual void | PushColorWriting (bool bEnable) |
virtual void | PushDepthTesting (bool bEnable) |
virtual void | PushDepthWriting (bool bEnable) |
void | PushModelTransform (const ON_Xform &mt) |
void | PushModelViewMatrix () |
void | PushModelViewMatrix (const ON_Xform &xf) |
void | PushProjection (const ON_Viewport &viewport) |
double | ScreenLength (double world_length) const |
const ON_Xform & | ScreenToClip () const |
const ON_Xform & | ScreenToClipInverse () const |
void | SetCamera (const ON_Viewport &) |
virtual int | SetClippingPlanes (const ON_SimpleArray< ON_ClippingPlaneInfo > &clipplanes) |
virtual int | SetClipRegion (int region_id) |
void | SetCurveAttributes (const CRhCurveAttributes &attributes) |
void | SetDpiScale (float scale) |
void | SetInstanceDefinitionTransform (const ON_Xform &idt) |
void | SetIsPreview (bool) |
void | SetLinearWorkflow (const CDisplayPipelineAttributes::LinearWorkflow &lw) |
void | SetModelTransform (const ON_Xform &mt) |
void | SetModelViewMatrix (const ON_Xform &xf) |
void | SetPreviewEnvironmentId (ON_UUID id) |
virtual void | SetStereoParallax (float) |
virtual void | SetStereoSeparation (float fSep) |
virtual int | SetZBiasLevel (int zbias) |
bool | ShadowsEnabled (void) const |
bool | UseClipPlanes () const |
bool | UseMaterials () |
const ON_Viewport & | VP () const |
Generic engine attributes... More... | |
float | WireDpiScale () const |
const ON_Xform & | WorldToCamera (bool includeModelXform=true) const |
const ON_Xform & | WorldToCameraInverse (bool includeModelXform=true) const |
const ON_Xform & | WorldToClip (bool includeModelXform=true) const |
world to screen transform = Viewport(world to clip)*m_ModelTransform More... | |
const ON_Xform & | WorldToClipInverse (bool includeModelXform=true) const |
ON_4dPoint | WorldToClippingPoint (const ON_3dPoint &point) const |
const ON_Xform & | WorldToScreen (bool includeModelXform=true) const |
world to screen transform = Viewport(world to screen)*m_ModelTransform More... | |
const ON_Xform & | WorldToScreenInverse (bool includeModelXform=true) const |
ON_2dPoint | WorldToScreenPoint (const ON_3dPoint &point) const |
virtual int | ZBiasLevel () const |
Public Member Functions inherited from ON_Object | |
ON_Object () ON_NOEXCEPT | |
ON_Object (const ON_Object &) | |
virtual | ~ON_Object () |
virtual ON_AggregateComponentStatus | AggregateComponentStatus () const |
bool | AttachUserData (class ON_UserData *pUserData) |
unsigned int | ClearAllComponentStates () const |
virtual unsigned int | ClearComponentStates (ON_COMPONENT_INDEX component_index, ON_ComponentStatus states_to_clear) const |
virtual unsigned int | ClearComponentStates (ON_ComponentStatus states_to_clear) const |
void | CopyUserData (const ON_Object &source_object) |
unsigned int | CopyUserData (const ON_Object &source_object, ON_UUID source_userdata_item_id, ON_Object::UserDataConflictResolution userdata_conflict_resolution) |
virtual ON__UINT32 | DataCRC (ON__UINT32 current_remainder) const |
virtual bool | DeleteComponents (const ON_COMPONENT_INDEX *ci_list, size_t ci_count) |
virtual void | DestroyRuntimeCache (bool bDelete=true) |
bool | DetachUserData (class ON_UserData *pUserData) |
virtual void | Dump (ON_TextLog &) const |
void | EmergencyDestroy () |
class ON_UserData * | FirstUserData () const |
virtual unsigned int | GetComponentsWithSetStates (ON_ComponentStatus states_filter, bool bAllEqualStates, ON_SimpleArray< ON_COMPONENT_INDEX > &components) const |
class ON_UserData * | GetUserData (const ON_UUID &userdata_uuid) const |
bool | GetUserString (const wchar_t *key, ON_wString &string_value) const |
int | GetUserStringKeys (ON_ClassArray< ON_wString > &user_string_keys) const |
int | GetUserStrings (ON_ClassArray< ON_UserString > &user_strings) const |
bool | IsCorrupt (bool bRepair, bool bSilentError, class ON_TextLog *text_log) const |
bool | IsKindOf (const ON_ClassId *pClassId) const |
virtual bool | IsValid (class ON_TextLog *text_log=nullptr) const |
virtual void | MarkAggregateComponentStatusAsNotCurrent () const |
virtual void | MemoryRelocate () |
virtual ON_UUID | ModelObjectId () const |
void | MoveUserData (ON_Object &source_object) |
unsigned int | MoveUserData (ON_Object &source_object, ON_UUID source_userdata_item_id, ON_Object::UserDataConflictResolution userdata_conflict_resolution, bool bDeleteAllSourceItems) |
virtual ON::object_type | ObjectType () const |
ON_Object & | operator= (const ON_Object &) |
void | PurgeUserData () |
virtual bool | Read (ON_BinaryArchive &binary_archive) |
virtual unsigned int | SetComponentStates (ON_COMPONENT_INDEX component_index, ON_ComponentStatus states_to_set) const |
virtual unsigned int | SetComponentStatus (ON_COMPONENT_INDEX component_index, ON_ComponentStatus status_to_copy) const |
bool | SetUserString (const wchar_t *key, const wchar_t *string_value) |
int | SetUserStrings (int count, const ON_UserString *user_strings, bool bReplace) |
virtual unsigned int | SizeOf () const |
bool | ThisIsNullptr (bool bSilentError) const |
void | TransformUserData (const class ON_Xform &xform) |
virtual bool | UpdateReferencedComponents (const class ON_ComponentManifest &source_manifest, const class ON_ComponentManifest &destination_manifest, const class ON_ManifestMap &manifest_map) |
int | UserStringCount () const |
virtual bool | Write (ON_BinaryArchive &binary_archive) const |
Static Public Member Functions | |
static unsigned int | AvailableGLLevel (bool *coreProfile) |
static bool | MakeDefaultContextCurrent () |
Activate the 'default' context. More... | |
Protected Member Functions | |
void | BlendMap (int nTex, float fBlend) |
void | Defaults () |
void | Destroy () |
bool | DisableGLContext () |
void | DisableTextures () |
bool | EnableGLContext () |
void | EnumMultiSampleModes (int) |
void | FlushCurveBuffer () override |
void | FlushMeshBuffer () override |
void | FlushPointBuffer () override |
int | GetClipPlanes (bool clippingCoordinates, ON_SimpleArray< ON_PlaneEquation > &planes) const |
bool | InitOpenGL () |
void | NotifyClippingPlanesChanged () override |
bool | NotifyFrameSizeChanged (int nWidth, int nHeight) override |
bool | NotifyProjectionChanged () override |
Notifier routines called by the pipeline framework... More... | |
void | SetupGLMatrices (bool model, bool projection) |
void | SetupMaterial (const CDisplayAttributeMaterial &material) |
void | SetupMaterial (int cullFaceMode, const CDisplayPipelineAttributes *da) |
bool | SetupPixelFormat () |
void | SetupTexture (UINT nId, UINT nTarget, ON_Texture &) |
void | Shutdown () |
void | ValidateFBO () |
Protected Member Functions inherited from CRhinoDisplayEngine | |
void | BufferMeshWires (CRhinoCacheHandle &cache, const CDisplayPipelineAttributes &da, const ON_Xform *xform, bool isSubD, const CRhinoSubDDisplayAttributes *subdAttrs) |
void | BufferShadedMesh (CRhinoCacheHandle &cache, const ON_Xform *xform) |
void | BufferShadedMesh (CRhinoCacheHandle &cache, ECullFaceMode cfm, const ON_Color &frontAmbient, const ON_Color &frontDiffuse, const std::shared_ptr< CDisplayPipelineMaterial > &material, const ON_SHA1_Hash &materialHash, const ON_Xform *xform) |
void | BufferShadedMeshes (class CRhVboMeshCache *buffer) |
void | ComputeZBiasValues (int bias, double &a, double &b, double &c, double &d, bool &use_d) const |
void | DrawBezier (int, const ON_4fPoint *, const CRhCurveAttributes &, int=1, int=0) |
void | DrawConstructionPlaneFarLines (ON_SimpleArray< ON_Line > &far_lines) |
void | DrawConstructionPlaneLine (const ON_Plane &near_plane, const ON_3dPoint &p, const ON_3dPoint &q, ON_SimpleArray< ON_Line > &far_lines) |
HDC | GetRenderTargetDC () const |
void | iShutdownEngine () |
void | Line (const ON_4fPoint &start, const ON_4fPoint &end) |
void | LineTo (const ON_4fPoint &) |
clipping coordinate point More... | |
void | MoveTo (const ON_4fPoint &) |
clipping coordinate point More... | |
void | MoveToLineTo (const ON_4fPoint &start, const ON_4fPoint &end) |
virtual void | SetRenderTarget (HDC pDC, bool bShutDown) |
virtual void | SetRenderTarget (HWND hWnd) |
void | SetScreenDrawTolerance (double, double, double) |
bool | SupportsVboBuffers () const |
New for V8 [begin]. More... | |
double | ZBiasDistance (double z, double w) const |
Protected Attributes | |
bool | m_bTransformShadowMatrix |
UINT | m_nTextureUnit |
Protected Attributes inherited from CRhinoDisplayEngine | |
double | m__zbias_a = 0 |
(near+far) More... | |
double | m__zbias_b = 0 |
(far-near) More... | |
double | m__zbias_c = 0 |
m__zbias_d*/(4*near*far) More... | |
double | m__zbias_d = 0 |
parallel proj bias or 0 for no zbias More... | |
bool | m__zbias_use_d = true |
true to return constance bias More... | |
bool | m_bInfiniteDepth = false |
bool | m_bInStereoMode = false |
Stereo viewing operations... More... | |
bool | m_bUseMaterials = true |
ON_Viewport | m_Camera |
ON_ClassArray< ON_Viewport > | m_CameraStack |
float | m_cliptol_x = 0.01f |
float | m_cliptol_y = 0.01f |
float | m_cliptol_z = 0.01f |
tolerance in clipping coordinates More... | |
CRhCurveAttributes | m_curve_attrs |
ON_SimpleArray< bool > | m_depth_testing_stack |
ON_SimpleArray< bool > | m_depth_writing_stack |
CRhinoDisplayPipeline * | m_dp = nullptr |
float | m_dpi_scale = 1.0f |
scaling for high resolution displays More... | |
int | m_draw_speed = 0 |
0 = accurate, 1 = fast, 2 = really More... | |
float | m_fStereoParallax = 1.0f |
float | m_fStereoSeparation = 1.0f |
HDC | m_hDC = nullptr |
Device Context handle render target. More... | |
HWND | m_hWnd = nullptr |
Engine display and drawing attributes... More... | |
ON_SimpleArray< ON_Xform > | m_modelview_matrix_stack |
ON_SimpleArray< ON_Xform > | m_ModelXformStack |
int | m_nDisplayHeight = 0 |
int | m_nDisplayWidth = 0 |
Viewport size attributes... More... | |
class CRhDisplayEnginePrivate * | m_private = nullptr |
float | m_stol_x = 0.75f |
float | m_stol_y = 0.75f |
float | m_stol_z = 1.00f |
screen buffer drawing tolerances More... | |
int | m_wire_depth = 0 |
Friends | |
class | CRhDisplayEnginePrivate_OGL |
class | CRhEngine_GL11 |
class | CRhEngine_GL21 |
class | CRhEngine_GL33 |
class | CRhEngine_GL40 |
class | CRhinoDisplayPipeline |
class | CRhOglEngineExtension |
class | CRhResourceManager_OGL |
Additional Inherited Members | |
Public Types inherited from ON_Object | |
enum | UserDataConflictResolution : unsigned char { UserDataConflictResolution::destination_object = 0, UserDataConflictResolution::source_object = 1, UserDataConflictResolution::source_copycount_gt = 2, UserDataConflictResolution::source_copycount_ge = 3, UserDataConflictResolution::destination_copycount_gt = 4, UserDataConflictResolution::destination_copycount_ge = 5, UserDataConflictResolution::delete_item = 6 } |
Copyright (c) 1993-2021 Robert McNeel & Associates. All rights reserved. Rhinoceros is a registered trademark of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete Rhino SDK copyright information see http://www.rhino3d.com/developer. OpenGL engine class...
CRhinoDisplayEngine_OGL::CRhinoDisplayEngine_OGL | ( | ) |
|
virtual |
|
overridevirtual |
0 = left, 1 = right...
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Add a light to the list of lights that the engine should use when displaying shaded geometry. Parameters: light: [in] the light information the engine should use to set up an graphics technology specific light
Reimplemented from CRhinoDisplayEngine.
|
static |
Return the available OpenGL level for the current instance of Rhino The level is returned as major*10+minor, so OpenGL 4.5 would return 45 Parameters: coreProfile: is set to true if operating in core profile mode
|
protected |
|
overridevirtual |
Returns: true if this engine can save depth buffer information
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
bool CRhinoDisplayEngine_OGL::CaptureFrameTo | ( | class CRhOpenGLTexture2D & | ) |
|
overridevirtual |
Description: Clear the depth buffer for this engine. If the engine does not support depth buffered drawing, then nothing is done.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: File the frame buffer with a bitmap image This function also clears the depth buffer for engines that support depth buffered drawing. Parameters: dib: [in] the image to draw into the frame buffer
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Fill the frame buffer with a gradient between four corner colors This function also clears the depth buffer for engines that support depth buffered drawing. Parameters: colorTopLeft: [in] the color in the top-left corner of the frame buffer colorBottomLeft: [in] the color in the bottom-left corner of the frame buffer colorTopRight: [in] the color in the top-right corner of the frame buffer colorBottomRight: [in] the color in the bottom-right corner of the frame buffer
Implements CRhinoDisplayEngine.
|
overridevirtual |
Description: Remove all cached texture information that may be stored locally or on the graphics card
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Copy color information from a bitmap into the back buffer Parameters: dib: [in] bitmap that contains the color information Returns: true if successful
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Copy color information in back buffer to a bitmap Parameters: dib: [out] bitmap that is created with color information from back buffer Returns: true if successful
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Copy the depth buffer information to a bitmap Parameters: dib: [out] the bitmap that is created with depth buffer information bConvertToImage: [in] if true, the depth information is converted into a grey scale image if false, each byte in the dib contains a depth value bInvertDepthValues: [in] if true, the values in the dib are flipped where a byte used to be 0 will now be 255 and a byte that used to be 255 will now be 0 pBackground: [in] If not NULL, this image will be place in the background of dib where no depth information was written to Returns: true if successful
Reimplemented from CRhinoDisplayEngine.
|
protected |
|
overridevirtual |
Returns: Number of bits per pixel used to describe the depth value
Reimplemented from CRhinoDisplayEngine.
int CRhinoDisplayEngine_OGL::DepthMode | ( | ) |
|
protected |
|
protected |
|
protected |
|
overridevirtual |
Description: Draw polyline defined in screen coordinates This is the low level 2d drawing routine used for drawing lines, rectangles,...
asPolyline | if false, each point pair is treated as independent lines |
Implements CRhinoDisplayEngine.
|
overridevirtual |
Description: Draw a bitmap Parameters: dib: [in] the bitmap to draw nX: [in] screen coordinate left location to draw top-left corner of dib nY: [in] screen coordinate top location to draw top-left corner of dib mask: [in] if set to a color, the dib is drawn using a color mask for transparency
Reimplemented from CRhinoDisplayEngine.
void CRhinoDisplayEngine_OGL::DrawBitmap | ( | const CRhinoDib & | dib, |
int | left, | ||
int | top, | ||
int | width, | ||
int | height | ||
) |
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
bool CRhinoDisplayEngine_OGL::DrawCombinedTextures | ( | UINT | nT1, |
UINT | nT2, | ||
int | nCOP, | ||
float | Scale, | ||
ON_Color | Color = ON_UNSET_COLOR |
||
) |
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Implements CRhinoDisplayEngine.
|
overridevirtual |
Description: Draws background environment into the frame buffer.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Draws a ground plane into the frame buffer.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Draw a set of lines Parameters: ld: [in] the line locations and attributes to draw
Reimplemented from CRhinoDisplayEngine.
|
override |
|
override |
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Implements CRhinoDisplayEngine.
|
overridevirtual |
Description: Draw a polygon using a set of points for the polygon border Parameters: points: [in] array of points in world coordinates to use for polygon border count: [in] number of elements in points array color: [in] draw color bFilled: [in] true = draw the polygon as a filled shape false = just draw the polygon border
Reimplemented from CRhinoDisplayEngine.
|
override |
|
overridevirtual |
Implements CRhinoDisplayEngine.
|
overridevirtual |
Description: Draws text with specified color, font and height
Implements CRhinoDisplayEngine.
|
overridevirtual |
Implements CRhinoDisplayEngine.
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Draws background bitmap image onto the construction plane.
Reimplemented from CRhinoDisplayEngine.
void CRhinoDisplayEngine_OGL::DrawViewportAlignedImage | ( | const class CRhOpenGLTexture & | image, |
bool | bProgramInUse | ||
) |
void CRhinoDisplayEngine_OGL::DrawViewportAlignedQuad | ( | bool | bProgramInUse | ) |
|
overridevirtual |
Description: Draws wallpaper image into the back buffer.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Turn on/off writing of information to the color buffer
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Depth-Buffered operations & attributes...
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description Turn on/off writing of information to the depth buffer for engines that support depth buffers
Reimplemented from CRhinoDisplayEngine.
|
protected |
|
overridevirtual |
"State" operations & attributes...
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Enables / disables multisampling.
Reimplemented from CRhinoDisplayEngine.
void CRhinoDisplayEngine_OGL::EnableShadowMap | ( | bool | bEnable = true | ) |
|
protected |
unsigned int CRhinoDisplayEngine_OGL::ExecutionLevel | ( | ) | const |
|
overridevirtual |
Description: Flushes any and all buffers used by the engine.
Reimplemented from CRhinoDisplayEngine.
|
overrideprotectedvirtual |
Reimplemented from CRhinoDisplayEngine.
|
overrideprotectedvirtual |
Reimplemented from CRhinoDisplayEngine.
|
overrideprotectedvirtual |
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: Number of bits per pixel for the frame buffer color values
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Gets the number of bits used to define each color channel for an individual pixel Parameters: red_bits: [out] number of bits dedicated to describing red level in pixel green_bits: [out] number of bits dedicated to describing green level in pixel blue_bits: [out] number of bits dedicated to describing blue level in pixel alpha_bits: [out] number of bits dedicated to describing alpha level in pixel
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: copy the color information in the back buffer to a bitmap Parameters: dib: [out] the bitmap that is created and holds the back buffer's values Returns: true if successful
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
protected |
|
overridevirtual |
Description: Read depth values into an array Parameters: buffer: [out] array large enough to hold width * height elements This array will hold the depth values left: [in] defines rectangle on viewport to get information from top: [in] defines rectangle on viewport to get information from width: [in] defines rectangle on viewport to get information from height: [in] defines rectangle on viewport to get information from Returns: true if successful
Reimplemented from CRhinoDisplayEngine.
class CRhDisplayEnginePrivate_OGL* CRhinoDisplayEngine_OGL::GetEngineGlPrivate | ( | ) |
class CRhOpenGLRenderer* CRhinoDisplayEngine_OGL::GetFrameBufferObject | ( | ) |
void CRhinoDisplayEngine_OGL::GetGlCameraToClip | ( | float | m[16], |
const ON_Xform * | extra | ||
) | const |
void CRhinoDisplayEngine_OGL::GetGlCameraToClipInverse | ( | float | m[16], |
const ON_Xform * | extra | ||
) | const |
void CRhinoDisplayEngine_OGL::GetGlClipToScreen | ( | float | m[16] | ) | const |
void CRhinoDisplayEngine_OGL::GetGlScreenToClip | ( | float | m[16] | ) | const |
void CRhinoDisplayEngine_OGL::GetGlWorldToCamera | ( | float | m[16], |
bool | includeModelTransform, | ||
const ON_Xform * | extra | ||
) | const |
void CRhinoDisplayEngine_OGL::GetGlWorldToCameraInverse | ( | float | m[16], |
bool | includeModelTransform, | ||
const ON_Xform * | extra | ||
) | const |
void CRhinoDisplayEngine_OGL::GetGlWorldToClip | ( | float | m[16], |
bool | includeModelTransform, | ||
const ON_Xform * | extra | ||
) | const |
void CRhinoDisplayEngine_OGL::GetGlWorldToClipInverse | ( | float | m[16], |
bool | includeModelTransform, | ||
const ON_Xform * | extra | ||
) | const |
|
overridevirtual |
Returns: The current multi-sample mode for this engine or -1 if multisampling is not supported
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: If this engine supports multisampling, this function retrieves a list of the multisampling modes available Parameters: modes: [out] list of multi-sample modes available Note: the values returned are engine specific, and only the underlying engine knows how to really interpret their meaning. The routine SetMultiSampleMode( N ) is used in conjunction with these return values, and again, only the engine knows what they mean and how they're interpreted when actually setting up multi-sampling.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description:
Reimplemented from CRhinoDisplayEngine.
HGLRC CRhinoDisplayEngine_OGL::GetRenderingContext | ( | ) | const |
Description: returns the OpenGL rendering context that this engine is working with. May be NULL if the engine has not created the rendering context.
|
overridevirtual |
Engine buffers support...
Reimplemented from CRhinoDisplayEngine.
|
protected |
|
overridevirtual |
Caching operations...
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Is this engine drawing using hardware acceleration? Returns: true if the engine is using hardware accelerated OpenGL or Direct3D
Reimplemented from CRhinoDisplayEngine.
bool CRhinoDisplayEngine_OGL::IsPreview | ( | void | ) | const |
bool CRhinoDisplayEngine_OGL::IsShadowMapEnabled | ( | ) |
const CDisplayPipelineAttributes::LinearWorkflow& CRhinoDisplayEngine_OGL::LinearWorkflow | ( | ) | const |
|
static |
Activate the 'default' context.
|
overridevirtual |
Returns: The maximum number of user defined clipping planes supported. This does not include the standard view frustum clipping planes. OpenGL and Direct3D will support different numbers of clipping planes based on the installed graphics card.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: The maximum number of decals supported for shading. OpenGL and Direct3D will support different numbers of decals based on the installed graphics card.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: The maximum number of lights supported for shading. OpenGL and Direct3D will support different numbers of lights based on the installed graphics card.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: The maximum number of object mappings supported for shading. OpenGL and Direct3D will support different numbers of object mappings based on the installed graphics card.
Reimplemented from CRhinoDisplayEngine.
int CRhinoDisplayEngine_OGL::MaxTextureCoords | ( | ) | const |
int CRhinoDisplayEngine_OGL::MaxTextureSize | ( | ) | const |
int CRhinoDisplayEngine_OGL::MaxTextureUnits | ( | ) | const |
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
overrideprotectedvirtual |
Reimplemented from CRhinoDisplayEngine.
|
overrideprotectedvirtual |
Description: Tell the engine that the size of the rectangle that it draws to has changed.
Reimplemented from CRhinoDisplayEngine.
|
overrideprotectedvirtual |
Notifier routines called by the pipeline framework...
Description: This routine is normally called by the pipeline framework because the current "display's" viewport projection has changed...This means that all of the commonly used engine attributes need to be updated.
Note: this routine should never be called haphazardly since it can be somewhat expensive performance-wise. However, if you or your display pipeline ever change the projection other than by through the standard pipeline mechanisms, then you must ensure that this routine gets called AFTER the changes, or update these attributes manually on an as-needed basis. Also, if your engine overrides this routine, then it is best that your implementation also call the derived class's implementation. Returns: true on success
Reimplemented from CRhinoDisplayEngine.
bool CRhinoDisplayEngine_OGL::PostProcessFrameBuffer | ( | ) |
ON_UUID CRhinoDisplayEngine_OGL::PreviewEnvironmentId | ( | void | ) | const |
void CRhinoDisplayEngine_OGL::ProcessLinearWorkflow | ( | const class CRhOpenGLTexture & | image, |
const float | gammaExponent | ||
) |
int CRhinoDisplayEngine_OGL::RenderPass | ( | ) | const |
|
overridevirtual |
Description: Should reset the engine back to some initial state...but at the same time try to maintain current state (ie. opened or closed). Typically this means saving the current state, shutting down the engine and then restarting the engine with the saved state
This is typically only used for things like changing the multisampling modes for an engine Returns: true if the reset operation was successful
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: true if a saved back buffer was successfully restored to the back buffer
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: true if a saved depth buffer was successfully restored to the engine depth buffer
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: true if this engine successfully saved back buffer color information to a location that can be retrieved at a later time
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: true is this engine successfully saved the depth buffer information to a location that can be retrieved at a later time
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Sets the current depth-testing mode used when drawing curves and lines. This basically determines whether lines are either always drawn in front, in back, or pays attention to the current depth value in the depth buffer. Parameters: nDepth: [in] 0 = Perform a depth-buffer test draw - this the normal mode of operation -1 = Always draw in back of everything else (i.e. on the far clipping plane) 1 = Always draw in front of everything else (i.e. on the near clipping plane) Note: All parameter values are currently clamped to [-1 .. 1] Returns: int : the previously used depth mode setting.
Reimplemented from CRhinoDisplayEngine.
void CRhinoDisplayEngine_OGL::SetIsPreview | ( | bool | ) |
void CRhinoDisplayEngine_OGL::SetLinearWorkflow | ( | const CDisplayPipelineAttributes::LinearWorkflow & | lw | ) |
Linear workflow support.
|
overridevirtual |
Description: Set the current multisampling mode for this engine Parameters: mode: [in] one of the modes retrieved from GetMultiSampleModes function Returns: true on success. If the engine does not support multisampling the return value will always be false
Reimplemented from CRhinoDisplayEngine.
void CRhinoDisplayEngine_OGL::SetPreviewEnvironmentId | ( | ON_UUID | ) |
|
overridevirtual |
Reimplemented from CRhinoDisplayEngine.
void CRhinoDisplayEngine_OGL::SetTextureCoords | ( | int | nTex, |
int | stride, | ||
const void * | |||
) | const |
|
protected |
Set up the 'legacy' OpenGL model and projection matrices with values matching the current camera
|
protected |
|
protected |
|
protected |
|
protected |
|
overridevirtual |
Description: Display the contents of the back buffer on to the front buffer Parameters: pDC: [in] device context to draw the back buffer colors to Returns: true if successful
Reimplemented from CRhinoDisplayEngine.
|
protected |
|
overridevirtual |
Description: Should completely shutdown and destroy everything associated with this engine... This includes any runtime buffers, dibs, or rendering contexts
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Engine initialization and cleanup operations...
Description: At the very beginning of drawing each frame the pipeline will call StartEngine to allow the engine to perform any required initializaion or context enabling
All subclasses that override this function should call this base class version of the function. Returns: True if the engine was successfully "started". False if something went wrong. If the function returns false, the pipeline will not be able to draw a frame.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Description: Near the end of drawing a frame the display pipeline will call StopEngine to tell the engine that it should flush any remaining buffers and perform and other task that must occur just prior to displaying the frame. Returns: true if the engine was successfully stopped. This is pretty much always true
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: True if the underlying engine technology support multisampling modes. This is used for anti-aliasing purposes and depends on the installed graphics card.
Reimplemented from CRhinoDisplayEngine.
|
overridevirtual |
Returns: True if the display engine support drawing triangles with lighting effects. Basically this is false for GDI and true for OpenGL and DirectX
Reimplemented from CRhinoDisplayEngine.
bool CRhinoDisplayEngine_OGL::SupportsStencilBuffer | ( | ) | const |
void CRhinoDisplayEngine_OGL::TransformShadowMatrix | ( | bool | bTransform | ) |
void CRhinoDisplayEngine_OGL::UseHardwareModes | ( | bool | = true | ) |
Specific OpenGL hardware information.
|
protected |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
protected |
|
protected |