diff options
Diffstat (limited to 'Source/Diagnostics/SliceDiagnostic.cpp')
-rw-r--r-- | Source/Diagnostics/SliceDiagnostic.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/Source/Diagnostics/SliceDiagnostic.cpp b/Source/Diagnostics/SliceDiagnostic.cpp index 994f990c6..9f365b39d 100644 --- a/Source/Diagnostics/SliceDiagnostic.cpp +++ b/Source/Diagnostics/SliceDiagnostic.cpp @@ -62,12 +62,13 @@ CreateSlice( const MultiFab& mf, const Vector<Geometry> &dom_geom, CheckSliceInput(real_box, slice_cc_nd_box, slice_realbox, slice_cr_ratio, dom_geom, SliceType, slice_lo, slice_hi, interp_lo); + int configuration_dim = 0; // Determine if interpolation is required and number of cells in slice // for (int idim = 0; idim < AMREX_SPACEDIM; ++idim) { // Flag for interpolation if required // if ( interp_lo[idim] == 1) { - interpolate = 1; + interpolate = 1; } // For the case when a dimension is reduced // @@ -86,10 +87,14 @@ CreateSlice( const MultiFab& mf, const Vector<Geometry> &dom_geom, if ( slice_grid_size >= refined_ncells ) { slice_grid_size = refined_ncells - 1; } - + } + configuration_dim += 1; } } + if (configuration_dim==1) { + amrex::Warning("The slice configuration is 1D and cannot be visualized using yt."); + } // Slice generation with index type inheritance // Box slice(slice_lo, slice_hi); |