필터 지우기
필터 지우기

How to blur a figure without blurring the axis?

조회 수: 4 (최근 30일)
Guy Nir
Guy Nir 2016년 11월 13일
댓글: Guy Nir 2016년 11월 13일
Hi,
I'm trying to add a blur (for instance with imfilter) to a 3D scatter plot (i.e. scatter3). To do so, I save the figure as jpg, load it, and use imfilter. However that blurs then entire image, including the axis and labels. Anyone has an idea of how to prevent of blurring the axis?

채택된 답변

Walter Roberson
Walter Roberson 2016년 11월 13일
save it with those items turned off, apply the blur, display the result with those items turned on.
  댓글 수: 3
Walter Roberson
Walter Roberson 2016년 11월 13일
편집: Walter Roberson 2016년 11월 13일
You would save the information separately, if you were not going to use it immediately.
Losing the 3D perspective is a problem you already have with the approach you are taking. If you are concerned about preserving 3D then you should not be considering using imfilter as that applies only to a particular 2D extract of a 3D perpective .
Note: when I say to turn off those items, I just mean set them to not be visible, not to change anything else about your scatter3().
Your mention of 3D suggests that you should not be using scatter3 at all.
If your points are far enough apart that they will never blur together, then you could consider converting each point into a patch representing a sphere, and then applying blur to the data represented by the patch objects to create new patches that you would then display.
If your points are not far enough apart, if they can blur together, then you should consider rendering your points into voxels, and then applying blurring to the voxels to produce a new voxel data array, and then rendering the voxel data array.
Guy Nir
Guy Nir 2016년 11월 13일
Dear Walter,
Thanks for your suggestions, I will give it a tray. I agree that saving, and reloading is not the most elegant way to do what I'm trying to. To make the axis not visible, I've used axis off, but I guess there are other ways. By rendering my points into voxels I guess you mean 3D array. The problem is that the matrix will be too big. Maybe I should try a sparse matrix, but am not sure whether a sparse matrix works well with filtering, and other functionalities. I'll try that patch idea! Thanks

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Lighting, Transparency, and Shading에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by