deleting pixels by manipulating pixel buffer