Navigation

Operators and Keywords

Function List:

C++ API

__marching_cube__.m File Reference


Functions

 if (isempty(tri_table)||isempty(edge_table))[edge_table
endif if ((nargin!=5 &&nargin!=6)||(nargout!=2 &&nargout!=3)) print_usage()
endif if (!ismatrix(xx)||!ismatrix(yy)||!ismatrix(zz)||!ismatrix(c)||...ndims(xx)!=3||ndims(yy)!=3||ndims(zz)!=3||ndims(c)!=3) error("xx
endif if (!size_equal(xx, yy, zz, c)) error("xx
endif if (any(size(xx)< [2 2 2])) error("grid size has to be at least 2x2x2")
endif if (!isscalar(iso)) error("iso needs to be scalar value")
endif if (nargin==6) if(!ismatrix(colors)||ndims(colors)!
 cc (idx)
 if (isempty(id)) T
 if (calc_cols) pp(id__
else pp (id__, 1:4, jj)
 if (!isempty(p)) p1
 pp (p1)
 pp (p2)
 pp (p3)]
 if (any(idp)) p(pp(idp
 elseif (nargin==11) p
else error ("Wrong number of arguments")
 if (any(id)) p(id
 p1y (id)
 p1z (id)]
 if (any(nid)) mu(nid)
 p (nid, 1:3)

Variables

 function [T, p, col]
persistent tri_table = []
 calc_cols = false
 lindex = 4
endif yy
endif zz
endif c have to be matrizes of dim
endif c are not the same size
endif n = size (c) - 1
 cc = zeros (n(1), n(2), n(3), "uint16")
 cedge = zeros (size (cc), "uint16")
 vertex_idx
for ii
 id = find (cedge)
return endif xyz_off = [1, 1, 1
 edges = [1 2
 offset = sub2ind (size (c), xyz_off(:, 1), xyz_off(:, 2), xyz_off(:, 3)) -1
 pp = zeros (length (id), lindex, 12)
 ccedge = [vec(cedge(id)), id]
 ix_offset = 0
for jj
 id_ = ccedge(id__, 2)
 id_c = ind2sub (size (cc), id_) sub2ind (size (c), ix, iy, iz)
 id1 = id_c + offset(edges(jj, 1))
 id2 = id_c + offset(edges(jj, 2))
 __pad6__
endfor T = []
 tri = tri_table(cc(id)+1, :)
 p = [id_, lindex*ones(size (id_, 1), 1),tri(id_, jj:jj+2)]
 p2 = sub2ind (size (pp), p(:,1), p(:,2), p(:,4))
 p3 = sub2ind (size (pp), p(:,1), p(:,2), p(:,5))
 col = []
 __pad7__
 __pad8__
endif mu = zeros (length (p1x), 1)
 __pad9__
endif endif nid = col1(id) !id

Function Documentation

cc ( idx   ) 

elseif ( nargin  = =11  ) 

else error ( "Wrong number of arguments"   ) 

if ( any(nid  ) 

if ( any(id  ) 

if ( any(idp)   ) 

if ( isemptyp  ) 

if ( calc_cols   ) 

if ( isempty(id  ) 

endif if ( nargin  = = 6  ) 

endif if ( isscalariso  ) 

endif if ( any(size(xx)< [2 2 2])   ) 

endif if ( size_equalxx, yy, zz, c  ) 

endif if ( !ismatrix(xx)||!ismatrix(yy)||!ismatrix(zz)||!ismatrix(c)||...ndims(xx)!  = 3 || ndims (yy) != 3 || ndims (zz) != 3 || ndims (c) != 3  ) 

endif if ( (nargin!=5 &&nargin!=6)||(nargout!=2 &&nargout!=3)   ) 

if ( isempty(tri_table)||isempty(edge_table)   ) 

p ( nid  ,
1:3   
)

p1y ( id   ) 

Type Constraints

p1z ( id   ) 

pp ( p3   ) 

pp ( p2   ) 

pp ( p1   ) 

else pp ( id__  ,
1:4  ,
jj   
)


Variable Documentation

endif calc_cols = false

cc = zeros (n(1), n(2), n(3), "uint16")

ccedge = [vec(cedge(id)), id]

endfor cedge = zeros (size (cc), "uint16")

if(calc_cols col = []

endif c have to be matrizes of dim

edges = [1 2

Initial value:

 __marching_cube__ (xx, yy, zz, c, iso, colors)
  
  persistent edge_table=[]

id = find (cedge)

id1 = id_c + offset(edges(jj, 1))

id2 = id_c + offset(edges(jj, 2))

id_ = ccedge(id__, 2)

id_c = ind2sub (size (cc), id_) sub2ind (size (c), ix, iy, iz)

Initial value:

1:8
    idx = c(vertex_idx{ii, :}) > iso

ix_offset = 0

Initial value:

1:12
    id__ = bitget (ccedge(:, 1), jj)

lindex = 4

endif mu = zeros (length (p1x), 1)

endif n = size (c) - 1

endif endif nid = col1(id) !id

offset = sub2ind (size (c), xyz_off(:, 1), xyz_off(:, 2), xyz_off(:, 3)) -1

endif endif endfor endfunction function p = [id_, lindex*ones(size (id_, 1), 1),tri(id_, jj:jj+2)]

p2 = sub2ind (size (pp), p(:,1), p(:,2), p(:,4))

p3 = sub2ind (size (pp), p(:,1), p(:,2), p(:,5))

pp = zeros (length (id), lindex, 12)

endif c are not the same size

T = []

tri = tri_table(cc(id)+1, :)

tri_table = []

Initial value:

 {1:n(1), 1:n(2), 1:n(3); ...
    2:n(1)+1, 1:n(2), 1:n(3); ...
    2:n(1)+1, 2:n(2)+1, 1:n(3); ...
    1:n(1), 2:n(2)+1, 1:n(3); ...
    1:n(1), 1:n(2), 2:n(3)+1; ...
    2:n(1)+1, 1:n(2), 2:n(3)+1; ...
    2:n(1)+1, 2:n(2)+1, 2:n(3)+1; ...
    1:n(1), 2:n(2)+1, 2:n(3)+1 }

return endif xyz_off = [1, 1, 1

endif yy

endif zz