Code covered by the BSD License
Alexandre Carvalho Leite
Alexandre Carvalho Leite (view profile)
25 Feb 2010
This function converts a surface into 3D faces of a DXF file.
Watch this File
The X, Y and Z matrix arguments can be used exactly as in the surf and mesh functions. But attention to the colors, because DXF fiels do not uses RGB palete. Instead they use a scaled color palete between 0 and 255.
You can fix the error by editing and re-uploading the file.
There is an error in the code line 45. The bug can be fixed by substituting it by:
fprintf(fid,'13\n %.4f\n 23\n %.4f\n 33\n %.4f\n',X(i+1,j),Y(i+1,j),Z(i+1,j));