0028726: Quantity_NameOfColor should be replaced by Quantity_Color in function input...
[occt.git] / src / V3d / V3d_SpotLight.cxx
index 0fa5b8f..e35a4a9 100644 (file)
@@ -59,7 +59,7 @@ V3d_SpotLight::V3d_SpotLight (const Handle(V3d_Viewer)& theViewer,
                               const Standard_Real theY,
                               const Standard_Real theZ,
                               const V3d_TypeOfOrientation theDirection,
-                              const Quantity_NameOfColor theColor,
+                              const Quantity_Color& theColor,
                               const Standard_Real theConstAttenuation,
                               const Standard_Real theLinearAttenuation,
                               const Standard_Real theConcentration,
@@ -88,7 +88,7 @@ V3d_SpotLight::V3d_SpotLight (const Handle(V3d_Viewer)& theViewer,
                               const Standard_Real theXp,
                               const Standard_Real theYp,
                               const Standard_Real theZp,
-                              const Quantity_NameOfColor theColor,
+                              const Quantity_Color& theColor,
                               const Standard_Real theConstAttenuation,
                               const Standard_Real theLinearAttenuation,
                               const Standard_Real theConcentration,
@@ -269,7 +269,6 @@ void V3d_SpotLight::Display (const Handle(V3d_View)& theView,
   Standard_Real X0,Y0,Z0,VX,VY,VZ;
   Standard_Real X1,Y1,Z1;
   Standard_Real DXRef,DYRef,DZRef,DXini,DYini,DZini;
-  Standard_Real R1,G1,B1;
   V3d_TypeOfRepresentation Pres;
 
 //  Creation of a structure slight of markable elements (position of the
@@ -316,8 +315,7 @@ void V3d_SpotLight::Display (const Handle(V3d_View)& theView,
   
 //Display of the position of the light.
 
-  this->Color(Quantity_TOC_RGB,R1,G1,B1);
-  Quantity_Color Col1(R1,G1,B1,Quantity_TOC_RGB);
+  const Quantity_Color Col1 = this->Color();
   Handle(Graphic3d_AspectLine3d) Asp1 = new Graphic3d_AspectLine3d();
   Asp1->SetColor(Col1);
   glight->SetPrimitivesAspect(Asp1);