19 #include <dtkCoreSupport/dtkAbstractData.h>
20 #include <dtkCoreSupport/dtkAbstractDataFactory.h>
38 return "axlFieldParametricVolumeTangentVectorWriter";
43 return "axlFieldParametricVolumeTangentVectorWriter";
48 return QStringList() <<
"axlFieldParametricVolumeTangentVector";
67 return !this->
accept(data);
74 QDomElement fieldElement = doc->createElement(
"field");
77 fieldElement.setAttribute(
"type", field->
identifier());
80 for(
int i = 0; i < 3;i++){
82 QDomElement parameter = doc->createElement(
"parameter");
83 parameter.setAttribute(
"value", QString::number(field->
parameter(i)));
84 parameter.setAttribute(
"channel", QString::number(i));
85 parameter.setAttribute(
"type",
"double");
86 fieldElement.appendChild(parameter);
95 QDomElement axlFieldParametricVolumeTangentVectorWriter::elementByWriter(
axlAbstractDataWriter *axl_writer, QDomDocument *doc, dtkAbstractData *data)
102 if(!axl_writer->
accept(data))
105 element = axl_writer->
write(doc, data);
QStringList handled(void) const
QString identifier(void) const
Returns the identifier of the field "axlFieldParametricVolumeTangentVector".
virtual bool accept(dtkAbstractData *data)=0
QString identifier(void) const
bool reject(dtkAbstractData *data)
axlFieldParametricVolumeTangentVectorWriter(void)
bool accept(dtkAbstractData *data)
QDomElement write(QDomDocument *doc, dtkAbstractData *data)
dtkAbstractDataWriter * createaxlFieldParametricVolumeTangentVectorWriter(void)
~axlFieldParametricVolumeTangentVectorWriter(void)
virtual QDomElement write(QDomDocument *doc, dtkAbstractData *data)=0
double parameter(int channel)
Returns the direction parameter for the tangentVector, the channel-th one.
QString description(void) const
static bool registered(void)
Class axlFieldParametricVolumeTangentVector defines an API for field which owns a BSpline Surface as ...