Adds grid example, adds some fixes for inverted grids