home *** CD-ROM | disk | FTP | other *** search
- // Example: 062 from Library Reference
- #include "..\3D-Ware\dddware.h"
- short VXangle=0, VZangle=0;
- short count;
- short main(void)
- {
- dddLoadColors("EXAMPLE.COL"); // Load in the color palette called 'example.col' to 'standardpal'.
- dddInitVideo();
- dddSetPal(dddstandardpal);
- dddInit3d();
- dddSetClipArea(0,319,0,199);
- dddSetHorizonClip(0,319,0,199,100);
- for (count=0; count<100; count++)
- {
- VXangle+=0x40; // Rotate around slowly in the X plane.
- VZangle+=0x400; // Rotate around fast in the Z plane.
- VZangle=(VZangle & 0xFFC0); // Make sure we have values between 0 and 0xFFC0
- dddHorizon(VXangle, VZangle); // Draw the horizon on the screen.
- dddScreenSwap();
- }
- dddRestoreVideo();
- dddClose3d();
- return 0;
- }
-