Make the dough by combining the flour, 1/4 cup of the sugar, cornmeal, rosemary, 1 teaspoon of the salt, and 12 tablespoons of the butter in the bowl of a food processor. Pulse until the mixture forms into pea-size crumbles. Drizzle in the ice-cold water, and pulse until the dough comes together. Turn the dough onto a clean counter, and form 2/3 of it into a flat disk. Repeat with the remaining dough. Wrap the disks in plastic wrap, and refrigerate for 1 hour.
On a lightly floured surface, roll the larger disk of dough into a 12" round. Gently transfer to a 9-inch pie plate. Trim the edges, leaving 1-inch of dough overhanging. Roll the small disk into an 8-inch square, and slice into 8 strips. Return all the dough to the refrigerator for 30 minutes.
In a large bowl, combine the apples, 3/4 cup of sugar, cornstarch, 1 tablespoon of cinnamon, lemon juice, vanilla, and last 1/2 teaspoon of salt. Spread the apple mixture into the prepared pie shell. Dot with the remaining 4 tablespoons of butter. Make a lattice by arranging 4 dough strips parallel across the top of the apple filling. Fold the 1st and 3rd strips back on themselves, then lay another strip perpendicular to them, just off center. Unfold 1st and 3rd strips, then lay another strip parallel to the 1st perpendicular strip. Repeat weaving pattern with the remaining dough strips, and refrigerate pie for 30 more minutes.
Heat oven to 400˚F. Trim edges of the pie dough and crimp. Brush with the egg mixture, then sprinkle with the last tablespoon of sugar and remaining cinnamon. Bake about 1 hour, until the crust is golden brown and apples are tender. Allow to cool completely before serving.