Commit b3e292bb authored by Mathieu Westphal's avatar Mathieu Westphal

Adding a Logo Source

This add a new source to ParaView, Logo.
This Logo is a simple vtk class that generate an ImageData
from a vtkTexture, it then pass it to a dedicated vtkLogoSourceRepresentation
that uses a vtkLogoRepresentation to display it on the render view.
parent 35518aca
......@@ -4,6 +4,7 @@
<Proxy group="sources" name="VectorText" />
<Proxy group="sources" name="TimeToTextConvertorSource" />
<Proxy group="sources" name="ArrowSource" />
<Proxy group="sources" name="LogoSource" />
<Proxy group="sources" name="TextSource" />
</Category>
<Category name="DataObjects" menu_label="&amp;Data Objects" preserve_order="1"
......
d653585d97c660c8c5be1c63b00e27870bd7e88c1a736113fba09f7207e4d3258542d129ac2e5315f67f2b00856b4aa75cd8fed2647a0fccaddf67934c6ed219
......@@ -76,6 +76,8 @@ ExternalData_Expand_Arguments(ParaViewData _
"DATA{${paraview_test_data_directory_input}/Data/non_convex_polygon.vtu}"
"DATA{${paraview_test_data_directory_input}/Data/office.binary.vtk}"
"DATA{${paraview_test_data_directory_input}/Data/pointSet.vtk}"
"DATA{${paraview_test_data_directory_input}/Data/ParaView_Mark.png}"
"DATA{${paraview_test_data_directory_input}/Data/ParaView_Logo.png}"
"DATA{${paraview_test_data_directory_input}/Data/porphyrin.cml}"
"DATA{${paraview_test_data_directory_input}/Data/quadraticTetra01.vtu}"
"DATA{${paraview_test_data_directory_input}/Data/quadratic_tets_with_ghost_cells.pvtu}"
......@@ -824,6 +826,7 @@ list(APPEND TESTS_WITH_BASELINES
TimeInspector.xml
TimeStepProgressBar.xml
Tessellate.xml
TextureUsages.xml
UndoRedo.xml
UndoRedo1.xml
UndoRedo2.xml
......@@ -1378,10 +1381,9 @@ set (FFTOverTime_THRESHOLD 70) # since there's a plot, account for minor
SET (ColorEditorVolumeControls_DISABLE_CS TRUE)
SET (ColorEditorVolumeControls_DISABLE_CRS TRUE)
# ViewSettingsDialog uses texture background which is currently supported only
# in local render mode.
SET (ViewSettingsDialog_DISABLE_CS TRUE)
# ViewSettingsDialog and TextureUsages uses texture which are not supported in pvcrs mode.
SET (ViewSettingsDialog_DISABLE_CRS TRUE)
SET (TextureUsages_DISABLE_CRS TRUE)
# MultiBlockAttributes1 requires selection which doesn't work on pvcrs
SET (MultiBlockAttributes1_DISABLE_CRS TRUE)
......
<?xml version="1.0" ?>
<pqevents>
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/SearchBox/AdvancedButton" command="set_boolean" arguments="true" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/ViewFrame/ProxyPanel/BackgroundEditor/BackgroundType" command="activated" arguments="Image" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/ViewFrame/ProxyPanel/BackgroundEditor/stackedWidget/page_3/1pqTextureSelectorPropertyWidget0/1pqTextureComboBox0" command="activated" arguments="Load ..." />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/ViewFrame/ProxyPanel/BackgroundEditor/stackedWidget/page_3/1pqTextureSelectorPropertyWidget0/1pqTextureComboBox0/LoadTextureDialog" command="filesSelected" arguments="$PARAVIEW_DATA_ROOT/Testing/Data/NE2_ps_bath.png" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/ViewFrame/ProxyPanel/BackgroundEditor/stackedWidget/page_3/1pqTextureSelectorPropertyWidget0/1pqTextureComboBox0" command="activated" arguments="NE2_ps_bath" />
<pqevent object="pqClientMainWindow/menubar" command="activate" arguments="menuSources" />
<pqevent object="pqClientMainWindow/menubar/menuSources/Alphabetical" command="activate" arguments="PlaneSource" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/Accept" command="activate" arguments="" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/DisplayFrame/ProxyPanel/Texture/1pqTextureComboBox0" command="activated" arguments="Load ..." />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/DisplayFrame/ProxyPanel/Texture/1pqTextureComboBox0/LoadTextureDialog" command="filesSelected" arguments="$PARAVIEW_DATA_ROOT/Testing/Data/ParaView_Mark.png" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/DisplayFrame/ProxyPanel/Texture/1pqTextureComboBox0" command="activated" arguments="ParaView_Mark" />
<pqevent object="pqClientMainWindow/menubar" command="activate" arguments="menuSources" />
<pqevent object="pqClientMainWindow/menubar/menuSources/Alphabetical" command="activate" arguments="LogoSource" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/PropertiesFrame/ProxyPanel/Texture/1pqTextureComboBox0" command="activated" arguments="Load ..." />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/PropertiesFrame/ProxyPanel/Texture/1pqTextureComboBox0/LoadTextureDialog" command="filesSelected" arguments="$PARAVIEW_DATA_ROOT/Testing/Data/ParaView_Logo.png" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/PropertiesFrame/ProxyPanel/Texture/1pqTextureComboBox0" command="activated" arguments="ParaView_Logo" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/Accept" command="activate" arguments="" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/DisplayFrame/ProxyPanel/Opacity/DoubleRangeWidget/DoubleLineEdit" command="set_string" arguments="0.5" />
<pqevent object="pqClientMainWindow/propertiesDock/propertiesPanel/scrollArea/qt_scrollarea_viewport/scrollAreaWidgetContents/DisplayFrame/ProxyPanel/Position/DoubleLineEdit0" command="set_string" arguments="0.08" />
<pqevent object="pqClientMainWindow/menubar" command="activate" arguments="menuTools" />
<pqevent object="pqClientMainWindow/menubar/menuTools" command="activate" arguments="actionTesting_Window_Size" />
</pqevents>
# Adding a Logo Source
A new Logo source has been added. The source enables a user to show
a 2D RGBA image projected on the foreground of the rendering plane.
Its size, position and opacity can be changed interactively.
It will enable users to display the logo of their company or laboratory
on the images and videos generated with ParaView.
......@@ -48,6 +48,7 @@ set(classes
vtkGlyph3DRepresentation
vtkImageSliceRepresentation
vtkImageVolumeRepresentation
vtkLogoSourceRepresentation
vtkMoleculeRepresentation
vtkMPIMoveData
vtkOutlineRepresentation
......
/*=========================================================================
Program: ParaView
Module: vtkLogoSourceRepresentation.cxx
Copyright (c) Kitware, Inc.
All rights reserved.
See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notice for more information.
=========================================================================*/
#include "vtkLogoSourceRepresentation.h"
#include "vtk3DWidgetRepresentation.h"
#include "vtkAbstractWidget.h"
#include "vtkAlgorithmOutput.h"
#include "vtkImageData.h"
#include "vtkInformation.h"
#include "vtkInformationVector.h"
#include "vtkLogoRepresentation.h"
#include "vtkObjectFactory.h"
#include "vtkPVCacheKeeper.h"
#include "vtkPVRenderView.h"
#include "vtkProperty2D.h"
vtkStandardNewMacro(vtkLogoSourceRepresentation);
vtkCxxSetObjectMacro(
vtkLogoSourceRepresentation, LogoWidgetRepresentation, vtk3DWidgetRepresentation);
//----------------------------------------------------------------------------
vtkLogoSourceRepresentation::vtkLogoSourceRepresentation()
{
this->CacheKeeper->SetInputData(this->ImageCache);
}
//----------------------------------------------------------------------------
vtkLogoSourceRepresentation::~vtkLogoSourceRepresentation()
{
this->SetLogoWidgetRepresentation(nullptr);
}
//----------------------------------------------------------------------------
void vtkLogoSourceRepresentation::SetVisibility(bool val)
{
this->Superclass::SetVisibility(val);
if (this->LogoWidgetRepresentation && this->LogoWidgetRepresentation->GetRepresentation())
{
this->LogoWidgetRepresentation->GetRepresentation()->SetVisibility(val);
this->LogoWidgetRepresentation->SetEnabled(val);
}
}
//----------------------------------------------------------------------------
void vtkLogoSourceRepresentation::SetInteractivity(bool val)
{
if (this->LogoWidgetRepresentation && this->LogoWidgetRepresentation->GetWidget())
{
this->LogoWidgetRepresentation->GetWidget()->SetProcessEvents(val);
}
}
//----------------------------------------------------------------------------
int vtkLogoSourceRepresentation::FillInputPortInformation(int, vtkInformation* info)
{
info->Set(vtkAlgorithm::INPUT_REQUIRED_DATA_TYPE(), "vtkImageData");
info->Set(vtkAlgorithm::INPUT_IS_OPTIONAL(), 1);
return 1;
}
//----------------------------------------------------------------------------
bool vtkLogoSourceRepresentation::AddToView(vtkView* view)
{
if (this->LogoWidgetRepresentation)
{
view->AddRepresentation(this->LogoWidgetRepresentation);
}
return this->Superclass::AddToView(view);
}
//----------------------------------------------------------------------------
bool vtkLogoSourceRepresentation::RemoveFromView(vtkView* view)
{
if (this->LogoWidgetRepresentation)
{
view->RemoveRepresentation(this->LogoWidgetRepresentation);
}
return this->Superclass::RemoveFromView(view);
}
//----------------------------------------------------------------------------
void vtkLogoSourceRepresentation::MarkModified()
{
if (!this->GetUseCache())
{
// Cleanup caches when not using cache.
this->CacheKeeper->RemoveAllCaches();
}
this->Superclass::MarkModified();
}
//----------------------------------------------------------------------------
bool vtkLogoSourceRepresentation::IsCached(double cache_key)
{
return this->CacheKeeper->IsCached(cache_key);
}
//----------------------------------------------------------------------------
int vtkLogoSourceRepresentation::RequestData(
vtkInformation* request, vtkInformationVector** inputVector, vtkInformationVector* outputVector)
{
// Pass caching information to the cache keeper.
this->CacheKeeper->SetCachingEnabled(this->GetUseCache());
this->CacheKeeper->SetCacheTime(this->GetCacheKey());
if (inputVector[0]->GetNumberOfInformationObjects() == 1)
{
vtkImageData* input = vtkImageData::GetData(inputVector[0], 0);
this->ImageCache->ShallowCopy(input);
}
this->ImageCache->Modified();
this->CacheKeeper->Update();
// It is tempting to try to do the data delivery in RequestData() itself.
// However, whenever a representation updates, ParaView GUI may have some
// GatherInformation() requests that happen. That messes up with any
// data-delivery code placed here. So we leave the data delivery to the
// REQUEST_PREPARE_FOR_RENDER() pass.
return this->Superclass::RequestData(request, inputVector, outputVector);
}
//----------------------------------------------------------------------------
int vtkLogoSourceRepresentation::ProcessViewRequest(
vtkInformationRequestKey* request_type, vtkInformation* inInfo, vtkInformation* outInfo)
{
if (!this->Superclass::ProcessViewRequest(request_type, inInfo, outInfo))
{
// i.e. this->GetVisibility() == false, hence nothing to do.
return 0;
}
if (request_type == vtkPVView::REQUEST_UPDATE())
{
vtkPVRenderView::SetPiece(inInfo, this, this->CacheKeeper->GetOutputDataObject(0));
vtkPVRenderView::SetDeliverToClientAndRenderingProcesses(inInfo, this,
/*deliver_to_client=*/true, /*gather_before_delivery=*/false);
}
else if (request_type == vtkPVView::REQUEST_RENDER())
{
vtkAlgorithmOutput* producerPort = vtkPVRenderView::GetPieceProducer(inInfo, this);
// since there's no direct connection between the mapper and the collector,
// we don't put an update-suppressor in the pipeline.
vtkImageData* image = vtkImageData::SafeDownCast(
producerPort->GetProducer()->GetOutputDataObject(producerPort->GetIndex()));
// Setup the logo
vtkLogoRepresentation* repr = vtkLogoRepresentation::SafeDownCast(this->LogoWidgetRepresentation
? this->LogoWidgetRepresentation->GetRepresentation()
: nullptr);
if (image && image->GetNumberOfPoints() > 0)
{
int dims[3];
image->GetDimensions(dims);
repr->SetImage(image);
repr->GetImageProperty()->SetOpacity(this->Opacity);
repr->SetVisibility(true);
float height = repr->GetPosition2()[1];
repr->SetPosition2(height * dims[0] / dims[1], height);
}
else
{
repr->SetVisibility(false);
}
}
return 1;
}
//----------------------------------------------------------------------------
void vtkLogoSourceRepresentation::PrintSelf(ostream& os, vtkIndent indent)
{
vtkIndent nextIndent = indent.GetNextIndent();
this->Superclass::PrintSelf(os, indent);
os << indent << "Opacity: " << this->Opacity << endl;
if (this->LogoWidgetRepresentation)
{
os << indent << "LogoWidgetRepresentation: " << endl;
this->LogoWidgetRepresentation->PrintSelf(os, nextIndent);
}
else
{
os << indent << "LogoWidgetRepresentation: (None)" << endl;
}
os << indent << "ImageCache: " << endl;
this->ImageCache->PrintSelf(os, nextIndent);
os << indent << "CacheKeeper: " << endl;
this->CacheKeeper->PrintSelf(os, nextIndent);
}
/*=========================================================================
Program: ParaView
Module: vtkLogoSourceRepresentation.h
Copyright (c) Kitware, Inc.
All rights reserved.
See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notice for more information.
=========================================================================*/
/**
* @class vtkLogoSourceRepresentation
*
* vtkLogoSourceRepresentation is a representation to show a Logo. The input is
* expected to a be a vtkImageData that can be passed to a vtkLogoRepresentation.
*/
#ifndef vtkLogoSourceRepresentation_h
#define vtkLogoSourceRepresentation_h
#include "vtkNew.h" // for vtkNew
#include "vtkPVClientServerCoreRenderingModule.h" //needed for exports
#include "vtkPVDataRepresentation.h"
class vtk3DWidgetRepresentation;
class vtkPVCacheKeeper;
class vtkImageData;
class VTKPVCLIENTSERVERCORERENDERING_EXPORT vtkLogoSourceRepresentation
: public vtkPVDataRepresentation
{
public:
static vtkLogoSourceRepresentation* New();
vtkTypeMacro(vtkLogoSourceRepresentation, vtkPVDataRepresentation);
void PrintSelf(ostream& os, vtkIndent indent) override;
//@{
/**
* Set the Logo widget.
*/
void SetLogoWidgetRepresentation(vtk3DWidgetRepresentation* widget);
vtkGetObjectMacro(LogoWidgetRepresentation, vtk3DWidgetRepresentation);
//@}
/**
* Remove all cache when marking modified
*/
void MarkModified() override;
/**
* Set the visibility.
*/
void SetVisibility(bool) override;
/**
* Set the interactivity.
*/
void SetInteractivity(bool);
//@{
/**
* Set the opacity of the logo
*/
vtkSetMacro(Opacity, double);
vtkGetMacro(Opacity, double);
//@}
/**
* vtkAlgorithm::ProcessRequest() equivalent for rendering passes. This is
* typically called by the vtkView to request meta-data from the
* representations or ask them to perform certain tasks e.g.
* PrepareForRendering.
*/
int ProcessViewRequest(vtkInformationRequestKey* request_type, vtkInformation* inInfo,
vtkInformation* outInfo) override;
protected:
vtkLogoSourceRepresentation();
~vtkLogoSourceRepresentation() override;
/**
* Fill input port information.
*/
int FillInputPortInformation(int port, vtkInformation* info) override;
/**
* Overridden to invoke vtkCommand::UpdateDataEvent.
*/
int RequestData(vtkInformation*, vtkInformationVector**, vtkInformationVector*) override;
/**
* Adds the representation to the view. This is called from
* vtkView::AddRepresentation(). Subclasses should override this method.
* Returns true if the addition succeeds.
*/
bool AddToView(vtkView* view) override;
/**
* Removes the representation to the view. This is called from
* vtkView::RemoveRepresentation(). Subclasses should override this method.
* Returns true if the removal succeeds.
*/
bool RemoveFromView(vtkView* view) override;
/**
* Overridden to check with the vtkPVCacheKeeper to see if the key is cached.
*/
bool IsCached(double cache_key) override;
vtkNew<vtkPVCacheKeeper> CacheKeeper;
vtkNew<vtkImageData> ImageCache;
vtk3DWidgetRepresentation* LogoWidgetRepresentation = nullptr;
double Opacity = 1.0;
private:
vtkLogoSourceRepresentation(const vtkLogoSourceRepresentation&) = delete;
void operator=(const vtkLogoSourceRepresentation&) = delete;
};
#endif
......@@ -102,11 +102,7 @@ bool vtkIsOutputTypeNonStandard(vtkPVXMLElement* hints, const int outputPort)
}
if (const char* type = child->GetAttribute("type"))
{
if (strcmp(type, "text") == 0)
{
return true;
}
else if (strcmp(type, "progress") == 0)
if (strcmp(type, "text") == 0 || strcmp(type, "progress") == 0 || strcmp(type, "logo") == 0)
{
return true;
}
......
......@@ -481,6 +481,10 @@ const char* vtkSMRenderViewProxy::GetRepresentationType(vtkSMSourceProxy* produc
{
return "ProgressBarSourceRepresentation";
}
else if (strcmp(childType, "logo") == 0)
{
return "LogoSourceRepresentation";
}
}
}
}
......
......@@ -674,6 +674,46 @@
</SubProxy>
<!-- End of ProgressBarWidgetRepresentation -->
</NewWidgetRepresentationProxy>
<!-- ================================================================== -->
<NewWidgetRepresentationProxy class="vtk3DWidgetRepresentation"
name="LogoWidgetRepresentation">
<Documentation>LogoWidgetRepresentation is a representation for a logo widget
</Documentation>
<IntVectorProperty command="SetEnabled"
default_values="1"
name="Enabled"
number_of_elements="1">
<BooleanDomain name="bool" />
<Documentation>Enable/Disable widget interaction.</Documentation>
</IntVectorProperty>
<IntVectorProperty command="SetUseNonCompositedRenderer"
default_values="1"
name="UseNonCompositedRenderer"
number_of_elements="1"></IntVectorProperty>
<SubProxy>
<Proxy name="Prop2D"
proxygroup="3d_widget_representations"
proxyname="LogoRepresentation"></Proxy>
<ExposedProperties>
<Property name="Visibility" />
<Property name="Position" />
<Property name="Position2" />
<Property name="PositionInfo" />
<Property name="Position2Info" />
</ExposedProperties>
</SubProxy>
<SubProxy>
<Proxy name="Widget"
proxygroup="3d_widgets"
proxyname="LogoWidget"></Proxy>
<ExposedProperties>
<Property name="ProcessEvents" />
<Property name="Selectable" />
<Property name="Resizable" />
</ExposedProperties>
</SubProxy>
<!-- End of LogoWidgetRepresentation -->
</NewWidgetRepresentationProxy>
</ProxyGroup>
<!-- ****************************************************************** -->
<ProxyGroup name="3d_widget_representations">
......@@ -1658,6 +1698,46 @@
<BooleanDomain name="bool" />
</IntVectorProperty>
</Proxy>
<!-- ================================================================== -->
<Proxy class="vtkLogoRepresentation"
name="LogoRepresentation">
<IntVectorProperty animateable="1"
command="SetVisibility"
default_values="1"
name="Visibility"
number_of_elements="1">
<BooleanDomain name="bool" />
</IntVectorProperty>
<DoubleVectorProperty command="SetPosition"
default_values="0.02 0.02"
information_property="PositionInfo"
name="Position"
number_of_elements="2">
<DoubleRangeDomain max="1 1"
min="0 0"
name="range" />
</DoubleVectorProperty>
<DoubleVectorProperty command="GetPosition"
information_only="1"
name="PositionInfo">
<SimpleDoubleInformationHelper />
</DoubleVectorProperty>
<DoubleVectorProperty command="SetPosition2"
default_values="0.08 0.08"
information_property="Position2Info"
name="Position2"
number_of_elements="2">
<DoubleRangeDomain max="1 1"
min="0 0"
name="range" />
</DoubleVectorProperty>
<DoubleVectorProperty command="GetPosition2"
information_only="1"
name="Position2Info">
<SimpleDoubleInformationHelper />
</DoubleVectorProperty>
</Proxy>
</ProxyGroup>
<!-- ****************************************************************** -->
<ProxyGroup name="3d_widgets">
......@@ -1825,6 +1905,31 @@
</IntVectorProperty>
<!-- End of ProgressBarWidget -->
</Proxy>
<Proxy base_proxygroup="3d_widgets"
base_proxyname="WidgetBase"
class="vtkLogoWidget"
name="LogoWidget">
<IntVectorProperty command="SetSelectable"
default_values="0"
name="Selectable"
number_of_elements="1">
<BooleanDomain name="bool" />
</IntVectorProperty>
<IntVectorProperty animateable="0"
command="SetResizable"
default_values="1"
name="Resizable"
number_of_elements="1">
<BooleanDomain name="bool" />
</IntVectorProperty>
<IntVectorProperty command="SetProcessEvents"
default_values="1"
name="ProcessEvents"
number_of_elements="1">
<BooleanDomain name="bool" />
</IntVectorProperty>
<!-- End of LogoWidget -->
</Proxy>
<Proxy base_proxygroup="3d_widgets"
base_proxyname="WidgetBase"
class="vtkBoxWidget2"
......
......@@ -1737,6 +1737,24 @@
<!-- End of TextSource -->
</SourceProxy>
<!-- ==================================================================== -->
<SourceProxy class="vtkPVLogoSource" name="LogoSource" label="Logo">
<ProxyProperty command="SetTexture"
name="Texture"
panel_widget="texture_selector"
null_on_empty="1" >
<ProxyGroupDomain name="groups">
<Group name="textures" />
</ProxyGroupDomain>
</ProxyProperty>
<Hints>
<Visibility replace_input="0" />
<OutputPort index="0"
name="Output-0"
type="logo" />
</Hints>
<!-- End of LogoSource -->
</SourceProxy>
<!-- ==================================================================== -->
<SourceProxy class="vtkQuerySelectionSource"
name="SelectionQuerySource">
<IntVectorProperty command="SetFieldType"
......
......@@ -8523,6 +8523,56 @@ Select how you want the text to be represented in the view.
<!-- End of ProgressBarSourceRepresentation -->
</RepresentationProxy>
<!-- =================================================================== -->
<RepresentationProxy class="vtkLogoSourceRepresentation"
name="LogoSourceRepresentation"
processes="client|dataserver|renderserver"
si_class="vtkSIProxy">
<Documentation>Representation proxy used to show a Logo.</Documentation>
<InputProperty command="SetInputConnection"
name="Input">
<DataTypeDomain name="input_type">
<DataType value="vtkImageData" />
</DataTypeDomain>
<Documentation>ImageData input for the representation.</Documentation>
</InputProperty>
<IntVectorProperty command="SetVisibility"
default_values="1"
name="Visibility"
number_of_elements="1"
panel_visibility="never">
<BooleanDomain name="bool" />
</IntVectorProperty>
<IntVectorProperty command="SetInteractivity"
default_values="1"
name="Interactivity"
number_of_elements="1">
<BooleanDomain name="bool" />
<Documentation>
Set whether user should be able to interactively place the Logo in the view.
</Documentation>
</IntVectorProperty>
<DoubleVectorProperty command="SetOpacity"
default_values="1.0"
name="Opacity"
number_of_elements="1">
<DoubleRangeDomain max="1"
min="0"
name="range" />
</DoubleVectorProperty>
<SubProxy command="SetLogoWidgetRepresentation">
<Proxy name="LogoWidgetRepresentation"
proxygroup="representations"
proxyname="LogoWidgetRepresentation"></Proxy>
<ExposedProperties>
<Property name="Position" />
<Property name="Position2" panel_visibility="never"/>
<Property name="PositionInfo" />
<Property name="Position2Info" />
</ExposedProperties>
</SubProxy>
<!-- End of LogoSourceRepresentation -->
</RepresentationProxy>
<!-- =================================================================== -->
<Proxy class="vtkPVFrustumActor"
name="FrustumWidget"
processes="client|dataserver|renderserver">
......
......@@ -105,6 +105,7 @@ set(classes
vtkPVGlyphFilterLegacy
vtkPVGridAxes3DActor
vtkPVLinearExtrusionFilter
vtkPVLogoSource
vtkPVMetaClipDataSet
vtkPVMetaSliceDataSet
vtkPVPLYWriter
......
/*=========================================================================
Program: ParaView
Module: vtkPVLogoSource.cxx
Copyright (c) Kitware, Inc.
All rights reserved.
See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notice for more information.
=========================================================================*/
#include "vtkPVLogoSource.h"
#include "vtkImageData.h"
#include "vtkInformation.h"
#include "vtkInformationVector.h"
#include "vtkObjectFactory.h"
#include "vtkStreamingDemandDrivenPipeline.h"
#include "vtkTexture.h"
vtkStandardNewMacro(vtkPVLogoSource);
vtkCxxSetObjectMacro(vtkPVLogoSource, Texture, vtkTexture);
//----------------------------------------------------------------------------
vtkPVLogoSource::vtkPVLogoSource()
{
this->SetNumberOfInputPorts(0);
}
//----------------------------------------------------------------------------
vtkPVLogoSource::~vtkPVLogoSource()
{
this->SetTexture(nullptr);
}
//----------------------------------------------------------------------------
int vtkPVLogoSource::RequestInformatio