summaryrefslogtreecommitdiff
path: root/src/Vrml/Vrml_Separator.cxx
blob: f5cded394cc30d2ce4ab47b251db0e9cebda637b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#include <Vrml_Separator.ixx>

 Vrml_Separator::Vrml_Separator(const Vrml_SeparatorRenderCulling aRenderCulling)
{
  myRenderCulling = aRenderCulling;
  myFlagPrint = 0;
}

 Vrml_Separator::Vrml_Separator()
{
  myRenderCulling = Vrml_AUTO;
  myFlagPrint = 0;
}

void Vrml_Separator::SetRenderCulling(const Vrml_SeparatorRenderCulling aRenderCulling)
{
  myRenderCulling = aRenderCulling;
}

Vrml_SeparatorRenderCulling Vrml_Separator::RenderCulling() const 
{
  return myRenderCulling;
}

Standard_OStream& Vrml_Separator::Print(Standard_OStream& anOStream) 
{
  if ( myFlagPrint == 0 )
    {
      anOStream  << "Separator {" << endl;
      if ( myRenderCulling != Vrml_AUTO )
	{
	 if ( myRenderCulling == Vrml_ON )
	    anOStream  << "    renderCulling" << "\tON" << endl;
	 else
	    anOStream  << "    renderCulling" << "\tOFF" << endl;
	}
      myFlagPrint = 1;
    } //End of if
  else 
    {
     anOStream  << '}' << endl;
     myFlagPrint = 0;
    }
 return anOStream;
}