From 93e869364fd735e674b496a9b0552348cdd22745 Mon Sep 17 00:00:00 2001 From: David Wells Date: Sun, 5 Feb 2023 19:04:09 -0500 Subject: [PATCH] Clean up some orientation code. --- source/base/qprojector.cc | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/source/base/qprojector.cc b/source/base/qprojector.cc index 4edf929662..8d3a1261bd 100644 --- a/source/base/qprojector.cc +++ b/source/base/qprojector.cc @@ -1330,10 +1330,13 @@ QProjector::DataSetDescriptor::face(const ReferenceCell &reference_cell, n_quadrature_points}; else if (dim == 3) { - const unsigned int orientation = (face_flip ? 4 : 0) + - (face_rotation ? 2 : 0) + - (face_orientation ? 1 : 0); - return {(6 * face_no + orientation) * n_quadrature_points}; + const unsigned char orientation = (face_flip ? 4 : 0) + + (face_rotation ? 2 : 0) + + (face_orientation ? 1 : 0); + Assert(orientation < 6, ExcInternalError()); + return {(reference_cell.n_face_orientations(face_no) * face_no + + orientation) * + n_quadrature_points}; } } -- 2.39.5