Standard_Boolean isASCIIMode = Standard_False;
Standard_Boolean isInParallel = Standard_False;
if (argc > 3) {
- isASCIIMode = (atoi(argv[3]) == 0);
+ isASCIIMode = (Draw::Atoi(argv[3]) == 0);
if (argc > 4) {
- isInParallel = (atoi(argv[4]) == 1);
+ isInParallel = (Draw::Atoi(argv[4]) == 1);
Standard::SetReentrant(isInParallel);
}
}
}
else {
TopoDS_Shape shape = DBRep::Get(argv[1]);
- Standard_Real defl = atof(argv[3]);
+ Standard_Real defl = Draw::Atof(argv[3]);
Standard_Integer type = 1;
- if(argc > 4) type = atoi(argv[4]);
+ if(argc > 4) type = Draw::Atoi(argv[4]);
type = Max(0, type);
type = Min(2, type);
Handle( MeshVS_Mesh ) aMesh = getMesh( argv[1], di );
if( !aMesh.IsNull() )
{
- Standard_Integer DisplayMode = 0;
- sscanf( argv[2], "%i", &DisplayMode );
+ Standard_Integer DisplayMode = Draw::Atoi (argv[2]);
Handle( AIS_InteractiveContext ) aContext = ViewerTest::GetAISContext();
Handle( MeshVS_Mesh ) aMesh = getMesh( argv[1], di );
if( !aMesh.IsNull() )
{
- Standard_Integer SelMode = 0;
- sscanf( argv[2], "%i", &SelMode );
+ Standard_Integer SelMode = Draw::Atoi (argv[2]);
Handle( AIS_InteractiveContext ) aContext = ViewerTest::GetAISContext();
Handle( MeshVS_Mesh ) aMesh = getMesh( argv[1], di );
if( !aMesh.IsNull() )
{
- Standard_Real r, g, b;
- sscanf( argv[2], "%lf", &r );
- sscanf( argv[3], "%lf", &g );
- sscanf( argv[4], "%lf", &b );
+ Standard_Real r = Draw::Atof (argv[2]);
+ Standard_Real g = Draw::Atof (argv[3]);
+ Standard_Real b = Draw::Atof (argv[4]);
aMesh->GetDrawer()->SetColor( (MeshVS_DrawerAttribute)Param, Quantity_Color( r, g, b, Quantity_TOC_RGB ) );
Handle( AIS_InteractiveContext ) aContext = ViewerTest::GetAISContext();
Handle( MeshVS_Mesh ) aMesh = getMesh( argv[1], di );
if( !aMesh.IsNull() )
{
- Standard_Integer mat;
- sscanf( argv[2], "%i", &mat );
+ Standard_Integer mat = Draw::Atoi (argv[2]);
Graphic3d_MaterialAspect aMatAsp =
(Graphic3d_MaterialAspect)(Graphic3d_NameOfMaterial)mat;
Handle( MeshVS_Mesh ) aMesh = getMesh( argv[1], di );
if( !aMesh.IsNull() )
{
- Standard_Real sh;
- sscanf( argv[2], "%lf", &sh );
+ Standard_Real sh = Draw::Atof (argv[2]);
aMesh->GetDrawer()->SetDouble( MeshVS_DA_ShrinkCoeff, sh );
Handle( AIS_InteractiveContext ) aContext = ViewerTest::GetAISContext();
if( aMode.IsEqual("elem1") || aMode.IsEqual("elem2") || aMode.IsEqual("nodal") || aMode.IsEqual("nodaltex") || aMode.IsEqual("none") )
{
Handle(MeshVS_PrsBuilder) aTempBuilder;
- Standard_Integer reflection = atoi(argv[3]);
+ Standard_Integer reflection = Draw::Atoi(argv[3]);
for (int count = 0 ; count < aMesh->GetBuildersCount(); count++ ){
aTempBuilder = Handle(MeshVS_PrsBuilder)::DownCast(aMesh->FindBuilder("MeshVS_ElementalColorPrsBuilder"));
}
const char* aWidthStr = argv[ 2 ];
- if ( aWidthStr == 0 || atof( aWidthStr ) <= 0 )
+ if ( aWidthStr == 0 || Draw::Atof( aWidthStr ) <= 0 )
{
di << "Width must be real value more than zero" << "\n";
return 0;
}
- double aWidth = atof( aWidthStr );
+ double aWidth = Draw::Atof( aWidthStr );
Handle(AIS_InteractiveContext) anIC = ViewerTest::GetAISContext();
if ( anIC.IsNull() )