DNA Calib 1.1
Project brief
Classes | Public Member Functions | Private Attributes | List of all members
dnac::ScaleCommand Class Reference

ScaleCommand is used to scale neutral joints, vertex positions and joint and blendshape deltas by a factor. More...

#include <ScaleCommand.h>

Inheritance diagram for dnac::ScaleCommand:
Inheritance graph
Collaboration diagram for dnac::ScaleCommand:
Collaboration graph

Classes

class  Impl
 

Public Member Functions

DNACAPI ScaleCommand (MemoryResource *memRes=nullptr)
 
DNACAPI ScaleCommand (float scale, Vector3 origin, MemoryResource *memRes=nullptr)
 
DNACAPI ~ScaleCommand ()
 
 ScaleCommand (const ScaleCommand &)=delete
 
ScaleCommandoperator= (const ScaleCommand &)=delete
 
DNACAPI ScaleCommand (ScaleCommand &&)
 
DNACAPI ScaleCommandoperator= (ScaleCommand &&)
 
DNACAPI void setScale (float scale)
 Method for setting the scale factor to multiply with. More...
 
DNACAPI void setOrigin (Vector3 origin)
 Method for setting the origin. More...
 
DNACAPI void run (DNACalibDNAReader *output) override
 
- Public Member Functions inherited from dnac::Command
virtual ~Command ()
 
virtual void run (DNACalibDNAReader *output)=0
 

Private Attributes

ScopedPtr< ImplpImpl
 

Detailed Description

ScaleCommand is used to scale neutral joints, vertex positions and joint and blendshape deltas by a factor.

Note
Only translation attributes of neutral joints and joint deltas are scaled.

Constructor & Destructor Documentation

◆ ScaleCommand() [1/4]

dnac::ScaleCommand::ScaleCommand ( MemoryResource memRes = nullptr)
explicit
147 : pImpl{makeScoped<Impl>(memRes)} {
148}
ScopedPtr< Impl > pImpl
Definition: ScaleCommand.h:49

◆ ScaleCommand() [2/4]

dnac::ScaleCommand::ScaleCommand ( float  scale,
Vector3  origin,
MemoryResource memRes = nullptr 
)
150 :
151 pImpl{makeScoped<Impl>(memRes)} {
152
153 pImpl->setScale(scale);
154 pImpl->setOrigin(origin);
155}
mat< L, L, T > scale(const vec< L, T > &factors)
Definition: Transforms.h:29

References pImpl, and tdm::affine::scale().

◆ ~ScaleCommand()

dnac::ScaleCommand::~ScaleCommand ( )
default

◆ ScaleCommand() [3/4]

dnac::ScaleCommand::ScaleCommand ( const ScaleCommand )
delete

◆ ScaleCommand() [4/4]

dnac::ScaleCommand::ScaleCommand ( ScaleCommand &&  )
default

Member Function Documentation

◆ operator=() [1/2]

ScaleCommand & dnac::ScaleCommand::operator= ( const ScaleCommand )
delete

◆ operator=() [2/2]

ScaleCommand & dnac::ScaleCommand::operator= ( ScaleCommand &&  )
default

◆ run()

void dnac::ScaleCommand::run ( DNACalibDNAReader output)
overridevirtual

Implements dnac::Command.

169 {
170 pImpl->run(static_cast<DNACalibDNAReaderImpl*>(output));
171}

References pImpl.

◆ setOrigin()

void dnac::ScaleCommand::setOrigin ( Vector3  origin)

Method for setting the origin.

Note
The origin is used to properly scale position values (vertex positions and neutral joint translations).
Parameters
originOrigin coordinates.
165 {
166 pImpl->setOrigin(origin);
167}

References pImpl.

◆ setScale()

void dnac::ScaleCommand::setScale ( float  scale)

Method for setting the scale factor to multiply with.

Parameters
scaleScale factor.
161 {
162 pImpl->setScale(scale);
163}

References pImpl, and tdm::affine::scale().

Member Data Documentation

◆ pImpl

ScopedPtr<Impl> dnac::ScaleCommand::pImpl
private

Referenced by run(), ScaleCommand(), setOrigin(), and setScale().


The documentation for this class was generated from the following files: