fixed bug from earlier where buffering size was being calculated based on X instead of Y, which caused problems with asymmetric stencils