MathGroup Archive 2010

[Date Index] [Thread Index] [Author Index]

Search the Archive

Fixing padding inside Inset

  • To: mathgroup at smc.vnet.net
  • Subject: [mg114917] Fixing padding inside Inset
  • From: Yaroslav Bulatov <yaroslavvb at gmail.com>
  • Date: Thu, 23 Dec 2010 03:51:01 -0500 (EST)

Below I have a Graphics3D and a corresponding Graphics using Inset
command. The box in Inset graphics is slightly larger and is cut off.
I can't seem to get them to display identically, any suggestions?

shape = {Opacity[0.5],
   GraphicsComplex[{{-1., 0., 0.}, {0., -1., 0.}, {0., 0., -1.}, {0.,
      0., 1.}, {0., 1., 0.}, {1., 0.,
      0.}}, {{{EdgeForm[GrayLevel[0.]],
       GraphicsGroup[{Polygon[{{4, 5, 1}, {1, 5, 3}, {1, 3, 2}, {4, 1,
             2}, {3, 5, 6}, {5, 4, 6}, {4, 2, 6}, {2, 3,
            6}}]}]}, {}, {}, {}, {}}}]};
gr1 = Graphics3D[shape, ImageSize -> 160,
  PlotRange -> {{-1, 1}, {-1, 1}, {-1, 1}}, ImageMargins -> 0,
  PlotRangePadding -> 0, ImagePadding -> 0]
gr2 = Graphics[Inset[gr1], ImageSize -> 160, ImagePadding -> 0,
  ImageMargins -> 0, PlotRangePadding -> 0]


  • Prev by Date: Combining Slider and SetterBar in Manipulate
  • Next by Date: Map function with 2 variables
  • Previous by thread: Re: Combining Slider and SetterBar in Manipulate
  • Next by thread: Re: Fixing padding inside Inset