打印

实例:添加效果

[复制链接]
174|0
手机看帖
扫描二维码
随时随地手机跟帖
跳转到指定楼层
楼主
cooldog123pp|  楼主 | 2024-7-26 23:48 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
ck, TI, ar, ST, se, AC
h0=figure('toolbar','none',...
    'position',[200 50 300 350],...
    'name','实例54');
h1=axes('parent',h0,...
    'position',[0.2 0.4 0.6 0.6],...
    'visible','off');
ezsurf('sin(sqrt(x.^2+y.^2))/sqrt(x.^2+y.^2)',[-6*pi,6*pi])
b1=uicontrol('parent',h0,...
    'units','points',...
    'tag','b1',...
    'style','pushbutton',...
    'string','设置',...
    'backgroundcolor',[0.75 0.75 0.75],...
    'position',[40 50 50 20],...
    'callback',[...
        'view(0,75);,',...
        'shading interp;,',...
        'lightangle(-45,30);,',...
        'k=findobj(gca,''type'',''surface'');,'...
        'set(k,''facelighting'',''phong'');,',...
        'set(k,''ambientstrength'',0.3);,',...
        'set(k,''diffusestrength'',0.8);,',...
        'set(k,''specularstrength'',0.9);,',...
        'set(k,''specularexponent'',25);,',...
        'set(k,''backfacelighting'',''unlit'')']);
b2=uicontrol('parent',h0,...
    'units','points',...
    'tag','b2',...
    'style','pushbutton',...
    'string','关闭',...
    'backgroundcolor',[0.75 0.75 0.75],...
    'position',[120 50 50 20],...
    'callback','close');


使用特权

评论回复

相关帖子

发新帖 我要提问
您需要登录后才可以回帖 登录 | 注册

本版积分规则

1754

主题

6214

帖子

29

粉丝