template<class DstArrayT, class SrcArrayT, class KerArrayT, class PixOpT, class RedOpT>
Line : Y direction, naive (inc), using value call.
Definition at line 307 of file FuncGenConv2dSep.h. References ArrayCH(), ArrayCPB(), ArrayCW(), ArrayInc(), PtrRead(), and PtrWrite(). 00310 { 00311 typedef typename DstArrayT::StorType DstStorT; 00312 typedef typename DstArrayT::ArithType DstArithT; 00313 typedef typename SrcArrayT::StorType SrcStorT; 00314 typedef typename SrcArrayT::ArithType SrcArithT; 00315 typedef typename KerArrayT::StorType KerStorT; 00316 typedef typename KerArrayT::ArithType KerArithT; 00317 00318 int height = ArrayCH(dst); 00319 int kerWidth = ArrayCW(ker); 00320 int kerBW = ArrayCW(ker) / 2; 00321 int srcInc = ArrayInc(src, 0, 1); 00322 KerArithT neutralElement = RedOpT::NeutralElement(); 00323 for (int y=0 ; y<height ; y++) 00324 { 00325 DstStorT* dPtr = ArrayCPB(dst, x, y); 00326 SrcStorT* sPtr = ArrayCPB(src, x, -kerBW + y); 00327 KerStorT* kPtr = ArrayCPB(ker, 0, 0); 00328 KerArithT result(neutralElement); 00329 for (int k=0; k<kerWidth; k++) 00330 { 00331 redOp.DoIt(result, pixOp.DoIt(PtrRead(sPtr, KerArithT()), 00332 PtrRead(kPtr, KerArithT()))); 00333 sPtr += srcInc; 00334 kPtr += KerArrayT::ElemSize(); 00335 } 00336 PtrWrite(dPtr, result); 00337 } 00338 }
Here is the call graph for this function:
|