srand[getpid[]] /* initialize some of the memory */ memset[heightmap, 0, MAPSIZE*MAPSIZE] memset[vpage, 0, RENDERWIDTH * RENDERHEIGHT] printf["Creating dx d fractal terrain\n", MAPSIZE, MAPSIZE] heightmap[0] = [rand[] 128] + 64 // initialize starting point on map CreateFractalMap[0, 0, MAPSIZE, MAPSIZE] printf["Smoothing terrain\n"] for [i = 0 i < 5 i++] SmoothMap[] MakeColorMap[]
标签: MAPSIZE initialize heightmap getpid
上传时间: 2013-12-25
上传用户:CSUSheep
Direct3D9初级教程,这个是对于diretcx入门的一个重要书籍,很好的介绍了dx的各个方向。
上传时间: 2017-05-16
上传用户:王庆才
DATAS SEGMENT w dw 0 keybuf db 255 db 0 db 255 dup(0) ;定义键盘输入需要的缓冲区 DATAS ENDS STACKS SEGMENT db 200 dup(?) STACKS ENDS CODES SEGMENT ASSUME CS:CODES,DS:DATAS,SS:STACKS START: MOV AX,DATAS MOV DS,AX mov dx,offset keybuf ;用0a号功能,输入一个字符串 mov ah,0ah ;用回车结束 int 21h mov dl,0ah ;再进行换行,以便在下一行显示转换后的字符串 mov ah,2 int 21h ; push ax ; push dx ; mov dl,cl ; mov ah,02 ; int 21h ; pop dx ; pop ax mov bx,offset keybuf+1 ;取出字符串的字符个数,作为循环的次数 mov cl,[bx] mov ch,0 mov ax,0 again: inc bx mov ax,[w] push bx mov bx,16 mul bx pop bx ;是小写字母,则转换为大写字母 mov [w],ax mov dl,[bx] ;取出一个字符, cmp dl,'9' jbe lab1 cmp dl,'F' jbe lab2 sub dl,32 lab2: sub dl ,07h lab1: sub dl,30h add [w],dx loop again mov ax,[w] mov bx,-1 push bx mov bx,10 lab3 :mov dx,0 div bx push dx cmp ax,0 jnz lab3 lab5: pop dx cmp dx,-1 jz lab4 add dl,30h mov ah,02 int 21h jmp lab5 ;循环,处理完整个字符串 lab4: MOV AH,4CH INT 21H CODES ENDS END START
标签: 汇编
上传时间: 2015-04-02
上传用户:wcc0310
Matlab 画三维立体图形 The aim of geom3d library is to handle and visualize 3D geometric primitives such as points, lines, planes, polyhedra... It provides low-level functions for manipulating 3D geometric primitives, making easier the development of more complex geometric algorithms. Some features of the library are: - creation of various shapes (3D points, 3D lines, planes, polyhedra...) through an intuitive syntax. Ex: createPlane(p1, p2, p3) to create a plane through 3 points. - derivation of new shapes: intersection between 2 planes, intersection between a plane and a line, between a sphere and a line... - functions for 3D polygons and polyhedra. Polyhedra use classical vertex-faces arrays (face array contain indices of vertices), and support faces with any number of vertices. Some basic models are provided (createOctaedron, createCubeoctaedron...), as well as some computation (like faceNormal or centroid) - manipulation of planar transformation. Ex.: ROT = createRotationOx(THETA); P2 = transformPoint3d(P1, ROT); - direct drawing of shapes with specialized functions. Clipping is performed automatically for infinite shapes such as lines or rays. Ex: drawPoint3d([50 50 25; 20 70 10], 'ro'); % draw some points drawLine3d([X0 Y0 Z0 DX DY DZ]); % clip and draw straight line Some functions require the geom2d package. Additional help is provided in geom3d/Contents.m file, as well as summary files like 'points3d.m' or 'lines3d.m'.
标签: Matlab 画三维立体图形
上传时间: 2015-11-02
上传用户:A1321
HyperSnap-DX 是个屏幕抓图工具,它不仅能抓住标准桌面程序还能抓取 DirectX, 3Dfx Glide 游戏和视频或 DVD 屏幕图。本程序能以 20 多种图形格式(包括:BMP, GIF, JPEG, TIFF, PCX 等)保存并阅读图片。可以用热键或自动记时器从屏幕上抓图。功能还包括:在所抓的图像中显示鼠标轨迹,收集工具,有调色板功能并能设置分辨率,还能选择从 TWAIN 装置中(扫描仪和数码相机)抓图。
上传时间: 2016-01-21
上传用户:a540958436
DirectX9实现3D俄罗斯方块 使用DX基础实现3D游戏
上传时间: 2018-01-14
上传用户:开星九座
100,DX,机器人,应用指令 100,DX,机器人,应用指令 100,DX,机器人,应用指令
上传时间: 2022-06-13
上传用户:xiaxiaojin