@apavlenko it has to be a Mat instead of an oclMat. The API only accepts Mat.