CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
l1t::L1TGT_GMT_TopoObject Struct Reference

#include <L1GTEvaluationInterface.h>

Inheritance diagram for l1t::L1TGT_GMT_TopoObject:
l1t::L1TGT_Interface< 64 > l1t::L1TGT_BaseInterface

Public Member Functions

 L1TGT_GMT_TopoObject (int valid=0, int pT=0, int phi=0, int eta=0, int mass=0, int qual=0)
 
ap_uint< WIDTHpack () const override
 
P2GTCandidate to_GTObject () const override
 
ap_uint< WIDTHunpack (const ap_uint< WIDTH > &packed) override
 
- Public Member Functions inherited from l1t::L1TGT_Interface< 64 >
std::size_t packed_width () const override
 
virtual ap_uint< Nunpack (const ap_uint< N > &)=0
 
- Public Member Functions inherited from l1t::L1TGT_BaseInterface
virtual ~L1TGT_BaseInterface ()
 

Public Attributes

ap_int< 8 > eta
 
ap_uint< 8 > mass
 
ap_int< 8 > phi
 
ap_uint< 8 > pT
 
ap_uint< 6 > qual
 
ap_uint< 1 > valid
 

Additional Inherited Members

- Static Public Attributes inherited from l1t::L1TGT_Interface< 64 >
static constexpr std::size_t WIDTH
 

Detailed Description

Definition at line 225 of file L1GTEvaluationInterface.h.

Constructor & Destructor Documentation

◆ L1TGT_GMT_TopoObject()

l1t::L1TGT_GMT_TopoObject::L1TGT_GMT_TopoObject ( int  valid = 0,
int  pT = 0,
int  phi = 0,
int  eta = 0,
int  mass = 0,
int  qual = 0 
)
inline

Member Function Documentation

◆ pack()

ap_uint<WIDTH> l1t::L1TGT_GMT_TopoObject::pack ( ) const
inlineoverridevirtual

Implements l1t::L1TGT_Interface< 64 >.

Definition at line 238 of file L1GTEvaluationInterface.h.

References eta, mass, phi, pT, qual, and valid.

◆ to_GTObject()

P2GTCandidate l1t::L1TGT_GMT_TopoObject::to_GTObject ( ) const
inlineoverridevirtual

Implements l1t::L1TGT_BaseInterface.

Definition at line 244 of file L1GTEvaluationInterface.h.

References eta, mass, phi, pT, qual, l1t::P2GTCandidate::setHwEta(), l1t::P2GTCandidate::setHwMass(), l1t::P2GTCandidate::setHwPhi(), l1t::P2GTCandidate::setHwPT(), and l1t::P2GTCandidate::setHwQual().

244  {
245  P2GTCandidate gt_object;
246  gt_object.setHwPT(static_cast<int>(pT) * 5); // TODO
247  gt_object.setHwPhi(static_cast<int>(phi) << 5);
248  gt_object.setHwEta(static_cast<int>(eta) << 5);
249  gt_object.setHwMass(mass);
250  gt_object.setHwQual(qual);
251 
252  return gt_object;
253  }

◆ unpack()

ap_uint<WIDTH> l1t::L1TGT_GMT_TopoObject::unpack ( const ap_uint< WIDTH > &  packed)
inlineoverride

Definition at line 240 of file L1GTEvaluationInterface.h.

References eta, l1t::l1t_unpack_int(), mass, phi, pT, qual, and valid.

Member Data Documentation

◆ eta

ap_int<8> l1t::L1TGT_GMT_TopoObject::eta

◆ mass

ap_uint<8> l1t::L1TGT_GMT_TopoObject::mass

◆ phi

ap_int<8> l1t::L1TGT_GMT_TopoObject::phi

◆ pT

ap_uint<8> l1t::L1TGT_GMT_TopoObject::pT

Definition at line 227 of file L1GTEvaluationInterface.h.

Referenced by pack(), to_GTObject(), and unpack().

◆ qual

ap_uint<6> l1t::L1TGT_GMT_TopoObject::qual

Definition at line 231 of file L1GTEvaluationInterface.h.

Referenced by pack(), to_GTObject(), and unpack().

◆ valid

ap_uint<1> l1t::L1TGT_GMT_TopoObject::valid

Definition at line 226 of file L1GTEvaluationInterface.h.

Referenced by pack(), and unpack().