如何导出具有抗锯齿功能的 GraphicsRow?
当我将两个对象放入 GraphicsRow 内部时,似乎关闭了它们的抗锯齿功能。任何人都可以看到下面示例中使用抗锯齿导出图形行的某种方法吗?
(来源:yaroslavvb.com)
我尝试过Style[#,Antialiasing->True]
和 Preferences 的各种组合,但没有运气。 我最接近的解决方法是以 4 倍分辨率对它们进行光栅化,但这会产生使用绝对厚度更改对象外观的副作用,例如,每个对象周围的框对象变得淡出。
picA = Graphics3D[{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}}]}]}, {}, {}, {}, {}}}]}];
picB = Graphics3D[{Opacity[0.5],
GraphicsComplex[{{-1., 0., 0.}, {-0.5, -0.8660254037844386,
0.}, {-0.5, 0.8660254037844386, 1.}, {0.,
0., -1.}, {0.5, -0.8660254037844386, 1.}, {0.5,
0.8660254037844386, 0.}, {1., 0.,
0.}}, {{{EdgeForm[GrayLevel[0.]],
GraphicsGroup[{Polygon[{{6, 7, 4}, {2, 1, 4}}],
Polygon[{{1, 2, 5, 3}, {6, 3, 5, 7}, {5, 2, 4, 7}, {3, 6, 4,
1}}]}]}, {}, {}, {}, {}}}]}];
GraphicsRow[{picA, picB}]
When I put two objects below inside GraphicsRow, it seems to turn off their antialiasing. Can anyone see some way to Export graphics row in example below with antialiasing?
(source: yaroslavvb.com)
I tried various combination of Style[#,Antialiasing->True]
and Preferences with no luck.
The closest work-around I is to Rasterize
them at 4 times the resolution, but that has a side effect of changing appearance of objects with AbsoluteThickness
, for instance, Box around each object becomes faded out.
picA = Graphics3D[{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}}]}]}, {}, {}, {}, {}}}]}];
picB = Graphics3D[{Opacity[0.5],
GraphicsComplex[{{-1., 0., 0.}, {-0.5, -0.8660254037844386,
0.}, {-0.5, 0.8660254037844386, 1.}, {0.,
0., -1.}, {0.5, -0.8660254037844386, 1.}, {0.5,
0.8660254037844386, 0.}, {1., 0.,
0.}}, {{{EdgeForm[GrayLevel[0.]],
GraphicsGroup[{Polygon[{{6, 7, 4}, {2, 1, 4}}],
Polygon[{{1, 2, 5, 3}, {6, 3, 5, 7}, {5, 2, 4, 7}, {3, 6, 4,
1}}]}]}, {}, {}, {}, {}}}]}];
GraphicsRow[{picA, picB}]
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
只是一个简短的评论:您是否在“首选项”对话框中启用了抗锯齿功能?
just a quick comment: have you enabled anti-aliasing in the Preferences dialog?