Configured header functions to use pointers instead of Mat type