mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0026734: Visualization, TKOpenGl - drop outdated UserDraw interfaces
Update ViewerTest and VoxelDemo to not use UserDraw callbacks. OpenGl_View::blitBuffers() - set 0 GLSL program after blit to avoid side effects on code that does not use shaders. Drop interfaces Aspect_GraphicCallbackProc, Graphic3d_CUserDraw, Graphic3d_Group::UserDraw(), OpenGl_GraphicDriver::UserDrawCallback(). V3d_View::SetWindow() - remove optional arguments initializing redraw callback. OpenGl_View, declare following methods as virtual for inheritance: redraw(), redrawImmediate(), render(), renderScene(), drawBackground(), renderStructs(). VocelClient_VisDrawer - do not include removed header
This commit is contained in:
@@ -55,7 +55,6 @@ Graphic3d_CStructure.cxx
|
||||
Graphic3d_CStructure.hxx
|
||||
Graphic3d_CStructurePtr.hxx
|
||||
Graphic3d_CTexture.hxx
|
||||
Graphic3d_CUserDraw.hxx
|
||||
Graphic3d_CView.cxx
|
||||
Graphic3d_CView.hxx
|
||||
Graphic3d_CycleError.hxx
|
||||
|
@@ -1,27 +0,0 @@
|
||||
// Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
//
|
||||
// This file is part of Open CASCADE Technology software library.
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or modify it under
|
||||
// the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
// by the Free Software Foundation, with special exception defined in the file
|
||||
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
// distribution for complete text of the license and disclaimer of any warranty.
|
||||
//
|
||||
// Alternatively, this file may be used under the terms of Open CASCADE
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
/*============================================================================*/
|
||||
/*==== Titre: Graphic3d_CUserDraw.hxx */
|
||||
/*==== Role : The header file of primitive type "CUserDraw" from Graphic3d */
|
||||
/*==== */
|
||||
/*==== Implementation: This is a primitive type implemented with typedef */
|
||||
/*============================================================================*/
|
||||
|
||||
#ifndef _Graphic3d_CUserDraw_HeaderFile
|
||||
#define _Graphic3d_CUserDraw_HeaderFile
|
||||
|
||||
#include <InterfaceGraphic_Graphic3d.hxx>
|
||||
typedef CALL_DEF_USERDRAW Graphic3d_CUserDraw;
|
||||
|
||||
#endif /*Graphic3d_CUserDraw_HeaderFile*/
|
@@ -14,7 +14,6 @@
|
||||
#ifndef _Graphic3d_CView_HeaderFile
|
||||
#define _Graphic3d_CView_HeaderFile
|
||||
|
||||
#include <Aspect_GraphicCallbackProc.hxx>
|
||||
#include <Aspect_Handle.hxx>
|
||||
#include <Aspect_PrintAlgo.hxx>
|
||||
#include <Aspect_RenderingContext.hxx>
|
||||
@@ -252,16 +251,10 @@ public:
|
||||
virtual Standard_Boolean SetImmediateModeDrawToFront (const Standard_Boolean theDrawToFrontBuffer) = 0;
|
||||
|
||||
//! Creates and maps rendering window to the view.
|
||||
//! @param theView [in] the view to associate with the window.
|
||||
//! @param theWindow [in] the window.
|
||||
//! @param theContext [in] the rendering context. If NULL the context will be created internally.
|
||||
//! @param theDisplayCB [in] the display callback function. If is not a NULL value, then the callback will be
|
||||
//! invoked at the end of the OCC graphic traversal and just before the swap of buffers.
|
||||
//! @param theClientData [in] the client data for the callback.
|
||||
virtual void SetWindow (const Handle(Aspect_Window)& theWindow,
|
||||
const Aspect_RenderingContext theContext = NULL,
|
||||
const Aspect_GraphicCallbackProc& theDisplayCB = NULL,
|
||||
const Standard_Address theClientData = NULL) = 0;
|
||||
const Aspect_RenderingContext theContext = NULL) = 0;
|
||||
|
||||
//! Returns the window associated to the view.
|
||||
virtual Handle(Aspect_Window) Window() const = 0;
|
||||
|
@@ -1074,30 +1074,6 @@ void Graphic3d_Group::Marker (const Graphic3d_Vertex& thePoint,
|
||||
AddPrimitiveArray (aPoints, theToEvalMinMax);
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : UserDraw
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void Graphic3d_Group::UserDraw (const Standard_Address /*theObject*/,
|
||||
const Standard_Boolean /*theToEvalMinMax*/,
|
||||
const Standard_Boolean theContainsFacet)
|
||||
{
|
||||
if (IsDeleted())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
// Without this modification, the group assumes the primitive contains
|
||||
// no polygons and does not require the Z-buffer for display.
|
||||
if (!MyContainsFacet && theContainsFacet)
|
||||
{
|
||||
myStructure->GroupsWithFacet (1);
|
||||
MyContainsFacet = Standard_True;
|
||||
}
|
||||
|
||||
Update();
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : Text
|
||||
// purpose :
|
||||
|
@@ -248,9 +248,6 @@ public:
|
||||
//! Creates a primitive array with single marker using AddPrimitiveArray().
|
||||
Standard_EXPORT void Marker (const Graphic3d_Vertex& thePoint, const Standard_Boolean theToEvalMinMax = Standard_True);
|
||||
|
||||
//! Creates a UserDraw primitive using obsolete API.
|
||||
Standard_EXPORT virtual void UserDraw (const Standard_Address theObject, const Standard_Boolean theToEvalMinMax = Standard_True, const Standard_Boolean theContainsFacet = Standard_False);
|
||||
|
||||
//! sets the stencil test to theIsEnabled state;
|
||||
Standard_EXPORT virtual void SetStencilTestOptions (const Standard_Boolean theIsEnabled) = 0;
|
||||
|
||||
|
Reference in New Issue
Block a user