?? sdf2circle.m
字號:
function f = sdf2circle(nrow,ncol, ic,jc,r)
% sdf2circle(nrow,ncol, ic,jc,r) computes the signed distance to a circle
% input:
% nrow: number of rows
% ncol: number of columns
% (ic,jc): center of the circle
% r: radius of the circle
% output:
% f: signed distance to the circle
%
% created on 04/26/2004
% author: Chunming Li
% email: li_chunming@hotmail.com
% Copyright (c) 2004-2006 by Chunming Li
[X,Y] = meshgrid(1:ncol, 1:nrow);
f = sqrt((X-jc).^2+(Y-ic).^2)-r;
%f=sdf2circle(100,50,51,25,10);figure;imagesc(f)
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -