diff --git a/python/dune/perftool/blockstructured/geometry.py b/python/dune/perftool/blockstructured/geometry.py
index 63bbaa4153f81c7f2cd3dd22a7d61ad2d96b96f4..dc9e48e1db63bc35ae9a1031aa9fffb33a804d12 100644
--- a/python/dune/perftool/blockstructured/geometry.py
+++ b/python/dune/perftool/blockstructured/geometry.py
@@ -2,7 +2,8 @@ from dune.perftool.pdelab.restriction import restricted_name
 
 from dune.perftool.generation import (get_backend,
                                       temporary_variable,
-                                      instruction)
+                                      instruction,
+                                      get_global_context_value)
 from dune.perftool.tools import get_pymbolic_basename
 from dune.perftool.options import (get_form_option,
                                    option_switch, get_option)
@@ -375,8 +376,18 @@ def apply_constant_to_global_transformation(name, local):
 def to_global(local):
     macro = name_point_in_macro(local)
     name = macro + "_global"
-    if get_form_option("constant_transformation_matrix"):
-        apply_constant_to_global_transformation(name, prim.Variable(macro))
+
+    it = get_global_context_value("integral_type")
+
+    if it == 'cell':
+        if get_form_option("constant_transformation_matrix"):
+            apply_constant_to_global_transformation(name, prim.Variable(macro))
+        else:
+            apply_default_to_global_transformation(name, prim.Variable(macro))
+    elif it == 'exterior_facet' or it == 'interior_facet':
+        from dune.perftool.pdelab.geometry import apply_to_global_transformation
+        apply_to_global_transformation(name, prim.Variable(macro))
     else:
-        apply_default_to_global_transformation(name, prim.Variable(macro))
+        raise NotImplementedError
+
     return prim.Variable(name)
diff --git a/python/dune/perftool/pdelab/geometry.py b/python/dune/perftool/pdelab/geometry.py
index e7e9b73427c2c80c5a97500c3a07cb688ede87a7..1eebaae31f620bd89cc59f2906edb52a8b44d1af 100644
--- a/python/dune/perftool/pdelab/geometry.py
+++ b/python/dune/perftool/pdelab/geometry.py
@@ -507,7 +507,7 @@ def define_element_corners(name):
     iname = "i_corner"
     domain(iname, n_corners)
     from dune.perftool.generation import instruction
-    instruction(code="{0}[{1}] = {2}.corner({3});".format(name, iname, name_cell_geometry(Restriction.NONE), iname),
+    instruction(code="{0}[{1}] = {2}.corner({3});".format(name, iname, name_geometry(), iname),
                 assignees=frozenset({name}),
                 within_inames=frozenset({iname}), within_inames_is_final=True)