/*********************************************************************
** Copyright (c) 1992-2025 MAK Technologies, Inc
** All rights reserved.
*********************************************************************/
//! \file coordTranslation.h
//! \ingroup matrix
//! \brief This file provides a declaration of the class DtCoordTranslation
#pragma once

#include <vlutil/vlMachineTypes.h>
#include <vlutil/vlUtil.h>
#include "vlVector.h"


#ifdef DtUSE_UTILITIES_NAMESPACE
namespace DtUSE_UTILITIES_NAMESPACE
{
#endif

//! \brief This class is used to translate between two points in Cartesian 
//! coordinate system.
//! \ingroup matrix
class DT_DLL_MATRIX DtCoordTranslation
{
public:
   DtCoordTranslation();
   DtCoordTranslation(const DtVector& toOriginInFromCoord);

   void setOffset(const DtVector& toOriginInFromCoord);
   void setByInverse(const DtCoordTranslation& to2from);

   void getOffset(DtVector& toOriginInFromCoord) const;
   DtVector offset() const;

   void coordTrans(const DtVector& from, DtVector& to) const;

protected:
   DtVector myOffset; //! "to" origin in base coordinates
};

#ifdef DtUSE_UTILITIES_NAMESPACE
}
#endif



