Is it possible to create transparent font on a graphics component?
조회 수: 8 (최근 30일)
이전 댓글 표시
I would like to create a text object which has transparent lettering, not just a transparent background. Id rather not have to convert it to an image as I want to still use the text properties/methods after creating the object in response to user input.
댓글 수: 0
답변 (2개)
Walter Roberson
2018년 3월 26일
Ummm, so where ever the transparent text is placed, the object "underneath" it along the line of sight should be made transparent? If there are multiple layers then should only the top-most along the line of sight be made transparent or everything all the way through? If there are two objects at equal distance along the line of sight then should they both be made transparent or should only one of them be, paying attention to to sortorder
https://blogs.mathworks.com/graphics/2014/11/04/sortmethod/
Now if it is to pay attention to sortorder then notice in Mike's 2D example that outlines can end up being drawn: how should a "one layer exposed only" rule be processed at those edges?
OK, and to confirm, exactly what is made transparent is to vary in real time as the user rotates the scene in three-space?
Would it be acceptable to to simply grab the axes background color and render the font in that? That would typically be an off-white.
댓글 수: 2
Walter Roberson
2018년 3월 26일
편집: Walter Roberson
2018년 3월 26일
You only want semi-transparent -- you want to specify an alpha parameter.
Alpha is not a documented property of text objects but it does exist. I am away from my desktop at the moment so I cannot check the details but I remember seeing it there. I would tend to suspect that Yair has documented it on his undocumentedmatlab site.
I probably will not be able to research this for about 10 or 12 hours so check his site.
참고 항목
카테고리
Help Center 및 File Exchange에서 Annotations에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!