How to put hit test off to Isosurface in matlab?

2 ビュー (過去 30 日間)
Vinith
Vinith 2013 年 7 月 14 日
I am using the code
isosurface(foo,fo);
caxis([0.2 0.5])
colorbar
grid on; axis equal; colormap default; alpha(0.3);
hold on;
I would want to make the hit test off to the isosurface so that, by clicking on the figure ButtonDownFcn of axis can be called.

採用された回答

Jan
Jan 2013 年 7 月 14 日
編集済み: Jan 2013 年 7 月 14 日
You can call patch explicitly to define additional properties:
patch(isosurface(foo,fo), 'HitTest', 'off');
  5 件のコメント
Jan
Jan 2013 年 7 月 15 日
編集済み: Jan 2013 年 7 月 15 日
So did you read doc isosurface already? There you find the exact description of how to provide the outputs of isosurface to patch (see "Example 2"):
[faces, verts, colors] = isosurface(foo, fo);
patch('Vertices', verts, 'Faces', faces, ...
'FaceVertexCData', colors, ...
'FaceColor','interp', ...
'edgecolor', 'interp', ...
'HitTest', 'off'); % <-- individual changes
If this does not help already, look at the other examples in the documentation.
Vinith
Vinith 2013 年 7 月 15 日
ya thanks it worked.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeScalar Volume Data についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by