View Issue Details

IDProjectCategoryView StatusLast Update
0023359CommunityOCCT:Visualizationpublic2012-10-04 15:57
ReporterTimo Assigned Tobugmaster  
PrioritynormalSeverityfeature 
Status closedResolutionduplicate 
Product Version6.5.3 
Target Version6.5.4 
Summary0023359: new display mode: "wireframe and shaded"
DescriptionWouldn't it be good to add a combination of wireframe and shaded mode (see CAD Exchanger) as a separate display mode to AIS_Shape?

It was proposed on the forum: http://www.opencascade.org/org/forum/thread_22134/?forum=3

Unitl now, it was necessary to derive an own subclass from AIS_Shape as proposed by Eric Thompson:

The trick is to derive your own class from AIS_Shape, and override its Compute( const Handle(PrsMgr_PresentationManager3d)& aPresentationManager, const Handle(Prs3d_Presentation)& aPresentation, const Standard_Integer aMode ) method.

Within your Compute method make the following two calls:

// Draw the wireframe
StdPrs_WFDeflectionShape::Add(aPresentation,Shape(),myDrawer);
// Draw the solid surfaces
StdPrs_ShadedShape::Add(aPresentation,Shape(),Attributes());


If this feature were added to standard OCC, it wouldn't be necessary to derive an own subclass for this purpose. As this display mode is available in many CAD applications today, many OCC-based applications would benefit from it.
In our application we simulated this mode until now by using shaded mode together with colored highlighting.
TagsNo tags attached.
Test case numberbugs vis CR23407_2

Attached Files

  • shaded and wireframe.PNG (34,684 bytes)

Activities

Timo

2012-07-26 18:21

developer  

shaded and wireframe.PNG (34,684 bytes)

Pawel

2012-09-26 19:17

developer   ~0021576

I guess this issue should be related to 23407 (don't have corresponding access rights myself).

abv

2012-09-27 08:31

manager   ~0021577

Last edited: 2012-09-27 08:32

That is correct, #23407 provides the desired behavior (see related changeset)

san

2012-09-28 22:54

developer   ~0021597

Dear Timo,

Could you please check the solution for #23407?

Timo

2012-10-01 12:36

developer   ~0021602

For now, I just reviewed the code.
My original idea was to add this behavior as an additional display mode to the AIS_DisplayMode enumeration and make it usable for AIS_Shape. Would this require still much work? Probably, then it would be most easy to use.

But accessing this behavior via the AIS_Drawer is also OK and it is more flexible as you can set the color and the line type.

However, a separate standard display mode would be beneficial in my opinion.

Would it be OK, if I do the final testing when a beta release for 6.6.0 is available as I'm not using GIT at the moment?

san

2012-10-04 11:08

developer   ~0021649

I believe the new AIS_Drawer settings are recognized at StdPrs_ShadedShape level so this change affects both XCAFPrs and AIS packages that use this tool class.

As I do not see any obvious benefits of having additional display mode (while obviously it is less efficient with respect to memory usage), I suggest we keep it as is for 6.5.4 release and collect the feedback to decide if it is OK or not.

Dear bugmaster,

Please close this issue as duplicate of #23407.

Pawel

2012-10-04 11:48

developer   ~0021651

From my point of view it is better not to add an additional display mode as this might require restructuring the application GUI etc.

Just my 50 cent...

bugmaster

2012-10-04 15:56

administrator   ~0021655

duplicate of 0023407.

Issue History

Date Modified Username Field Change
2012-07-26 18:21 Timo New Issue
2012-07-26 18:21 Timo Assigned To => san
2012-07-26 18:21 Timo File Added: shaded and wireframe.PNG
2012-09-26 19:17 Pawel Note Added: 0021576
2012-09-27 08:26 abv Changeset attached => occt master a2d5ab2e
2012-09-27 08:31 abv Note Added: 0021577
2012-09-27 08:31 abv Status new => resolved
2012-09-27 08:31 abv Target Version => 6.5.4
2012-09-27 08:32 abv Note Edited: 0021577
2012-09-27 08:33 abv Test case number => bugs vis CR23407_2
2012-09-28 22:54 san Note Added: 0021597
2012-09-28 22:54 san Assigned To san => Timo
2012-09-28 22:54 san Status resolved => feedback
2012-10-01 12:36 Timo Note Added: 0021602
2012-10-01 12:36 Timo Status feedback => assigned
2012-10-04 11:08 san Note Added: 0021649
2012-10-04 11:08 san Assigned To Timo => bugmaster
2012-10-04 11:08 san Status assigned => feedback
2012-10-04 11:48 Pawel Note Added: 0021651
2012-10-04 15:56 bugmaster Note Added: 0021655
2012-10-04 15:56 bugmaster Status feedback => closed
2012-10-04 15:57 bugmaster Resolution open => duplicate