Merge topic 'export_color'

dd4efb51 Uses `Color` in the unit tests for basic sanity check
812f11d3 Moves class-wide visibility macro to just the static class members.
68648863 Exports Color class, adding visibility to static members

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !850
This commit is contained in:
Matt Larsen 2017-08-02 19:58:59 +00:00 committed by Kitware Robot
commit 77a9e53066
2 changed files with 10 additions and 4 deletions

@ -20,6 +20,8 @@
#ifndef vtk_m_rendering_Color_h
#define vtk_m_rendering_Color_h
#include <vtkm/rendering/vtkm_rendering_export.h>
#include <iostream>
#include <vtkm/Types.h>
namespace vtkm
@ -135,10 +137,11 @@ public:
return out;
}
static Color white, black;
static Color red, green, blue;
static Color cyan, magenta, yellow;
static Color gray10, gray20, gray30, gray40, gray50, gray60, gray70, gray80, gray90;
static VTKM_RENDERING_EXPORT Color white, black;
static VTKM_RENDERING_EXPORT Color red, green, blue;
static VTKM_RENDERING_EXPORT Color cyan, magenta, yellow;
static VTKM_RENDERING_EXPORT Color gray10, gray20, gray30, gray40, gray50, gray60, gray70, gray80,
gray90;
};
}
} //namespace vtkm::rendering

@ -26,6 +26,7 @@
#include <vtkm/rendering/Actor.h>
#include <vtkm/rendering/Camera.h>
#include <vtkm/rendering/Canvas.h>
#include <vtkm/rendering/Color.h>
#include <vtkm/rendering/Mapper.h>
#include <vtkm/rendering/Scene.h>
#include <vtkm/rendering/View1D.h>
@ -97,6 +98,7 @@ void Render(const vtkm::cont::DataSet& ds,
{
MapperType mapper;
CanvasType canvas(512, 512);
canvas.SetBackgroundColor(vtkm::rendering::Color::white);
vtkm::rendering::Scene scene;
scene.AddActor(vtkm::rendering::Actor(
@ -115,6 +117,7 @@ void Render(const vtkm::cont::DataSet& ds,
{
MapperType mapper;
CanvasType canvas(512, 512);
canvas.SetBackgroundColor(vtkm::rendering::Color::white);
vtkm::rendering::Scene scene;
//DRP Actor? no field? no colortable (or a constant colortable) ??