How to prevent LATEX-labels in MATLAB GUI to become blurry?

前端 未结 1 716
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-01-12 07:10

Within my current MATLAB GUI project, i have two axes objects. The first is used by the workaround \"uibutton\" (I don\'t use GUIDE) in order to display a LaTeX-formula (as

1条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2021-01-12 07:12

    Check your figure properties before and after you draw the 3D plot

    get(gcf, 'renderer')
    

    My guess is that plotting the 3D function changes the renderer from the default ("painters") to another (likely OpenGL). Matlab's Latex rendering does not seem to play well with zbuffer or OpenGL (these produce bitmaps rather than line art).

    You may be stuck if painters can't render your 3D graphics properly, but you can try to force it by setting the renderer manually back to painters

    set(gcf, 'renderer', 'painters')
    

    0 讨论(0)
提交回复
热议问题