IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
shiftRight.h
Go to the documentation of this file.
1 // shiftRight.h:
3 // -----------------
4 //
14 
15 #ifndef __IPSDKUTIL_INSTRUCTIONSET_LOGICAL_SHIFTRIGHT_H__
16 #define __IPSDKUTIL_INSTRUCTIONSET_LOGICAL_SHIFTRIGHT_H__
17 
22 
23 namespace ipsdk {
24 namespace simd {
25 
28 
30 
31 template <eInstructionSet::domain instructionSet, class PackT>
32 IPSDK_FORCEINLINE
33 PackT
34 shiftRight(const PackT& in, ipUInt8 nbBits)
35 {
36  typedef typename PackT::DataType T;
37  return detail::BinaryPackOp<instructionSet, typename PackT::DataType,
39  //return detail::ShiftRightPack<instructionSet, T>::act(in, nbBits);
40 }
41 
42 template <eInstructionSet::domain instructionSet, class PackT>
43 IPSDK_FORCEINLINE
44 void
45 shiftRight(const PackT& in, ipUInt8 nbBits, PackT& out)
46 {
47  typedef typename PackT::DataType T;
48  detail::BinaryPackOp<instructionSet, typename PackT::DataType,
49  detail::ShiftRightReg<instructionSet, typename PackT::DataType> >::actPackScalar(in, nbBits, out);
50 }
51 
52 /*
53 template <eInstructionSet::domain instructionSet, typename TIn, typename TOut>
54 IPSDK_FORCEINLINE
55 typename IS2Pack<instructionSet, TOut>::Type
56 operator>>(const typename IS2Pack<instructionSet, TIn>::Type& in,
57  ipUInt8 nbBits)
58 {
59  typename IS2Pack<instructionSet, TOut>::Type out;
60  shiftRight<instructionSet, TIn, TOut>(in, nbBits, out);
61  return out;
62 }*/
63 
66 
67 } // end of namespace simd
68 } // end of namespace ipsdk
69 
70 #endif // __IPSDKUTIL_INSTRUCTIONSET_LOGICAL_SHIFTRIGHT_H__
Defines the IPSDK_FORCEINLINE.
Main namespace for IPSDK library.
Definition: AlgorithmFunctionEfficiency.h:22
uint8_t ipUInt8
Base types definition.
Definition: BaseTypes.h:49
Vector DataType
data type used for estimation
Definition: EstimationTypes.h:58
IPSDK_FORCEINLINE PackT shiftRight(const PackT &in, ipUInt8 nbBits)
shiftRight function
Definition: shiftRight.h:34
Definition of import/export macro for library.
Definition: ShiftRightReg.h:30
Definition: BinaryPackOp.h:31