DiscussionsIssue archiveOCCT:Visualization

Archived issue #0028033

Visualization - Graphic3d_Camera::ZFitAll() throws exception on camera rotation

Open CASCADEOCCT:Visualizationclosed2 public notes

Search issues

Description

ZRange computed by Graphic3d_Camera::ZFitAll() throws exception "ZFar should be greater than ZNear" within Graphic3d_Camera::SetZRange() in some cases during camera rotation leading to application crash:

09 pc 00677d5b /data/app/org.opencascade.cadassistant-1/lib/arm/libCADAssistant.so (_ZNK21Standard_ProgramError5ThrowEv+42)
10 pc 0067801b /data/app/org.opencascade.cadassistant-1/lib/arm/libCADAssistant.so (_ZN21Standard_ProgramError5RaiseEPKc+38)
11 pc 00ae4b37 /data/app/org.opencascade.cadassistant-1/lib/arm/libCADAssistant.so (_ZN16Graphic3d_Camera9SetZRangeEdd+110)
12 pc 00ad44fb /data/app/org.opencascade.cadassistant-1/lib/arm/libCADAssistant.so (_ZNK8V3d_View7ZFitAllEd+110)
13 pc 00ad7573 /data/app/org.opencascade.cadassistant-1/lib/arm/libCADAssistant.so (_ZN8V3d_View6RotateEddddddj+898)
14 pc 00ad77ef /data/app/org.opencascade.cadassistant-1/lib/arm/libCADAssistant.so (_ZN8V3d_View8RotationEii+158)

Steps to reproduce

This is not the same test case as call stack in bug description (which is unknown), but having the same effect:
pload MODELING VISUALIZATION
vclear
vinit View1
vaxo
circle c 0 0 0 0.001
mkedge e c
wire   w e
plane  s
mkface f1000 s w
ttranslate f1000 1000 0 0
vpoint v1000 1000 0 0.001
vdisplay -dispMode 1 f1000
vstereo anaglyph
vfit

vpoint v0 0 0 0

Public activity

2 archived notes

Participants are labeled by their role within this record.

01Author
Patch for #0029837 adds protection that should eliminate this sudden assertion, although the logic in the method should be checked to understand if this is expected or invalid behavior.
02Author
Dear Commenter 1,

please close the issue as no more reproducible.

Related records