What: "virtual" circling around through the clouds Hot points: - simple virtual reality "thing", of a flight-simulator kind - with the complete source and lots of comments/explanations - can take any height map and flight/pan around it - NO QuickDraw3D, all rendering/graphics is done by the code itself - includes the source for a small class library to handle full-color Mac windows/user items /offscreen GrafWorlds - C++ classes for Dialogs and dialog (user) items; consistent OO design with late binding - on-the-fly "patching" of CDEF without even touching the trap table, or any of the system code - animation NOT through null-events Keywords: voxel 3D rendering, visualization, animation, elevation map, panning Contents: Readme - this file New Venus - application itself (PowerMac) Venus.mu - project to build it Venus.mu.rsrc - 'clut', pltt, dialog and control resources main.cc - Where the main dialog class is declared and implemented view_3d.cc - render a clouds map in 3D and make a view from the cockpit view_2d.cc - make a 'view-from-above' and do circling around ValueControl.* - C++ class for a slider displaying its current setting window.h \ SimpleWindow.cc \ my own very simple "MacApp": a classlib for Dialog.* / handling color Mac windows and offscreen GrafWorlds EventHandlers.* / The source code contains many comments to show what a particular piece of code does, as well as some tricks involved Language: CodeWarrior C++ 7.1 System: System 7.x; binaries are for a PowerMac. Note: Some ancillary code is provided in a binary form (as compiled libraries) for compactness. The corresponding source code can be grabbed from the Info-Mac (/info-mac/dev/lib/gray-image-21-cpp.hqx) or ftp://replicant.csci.unt.edu/~oleg/ftp/grayimage-21.cpt.hqx See http://mozart.compsci.com/~oleg/ftp/ for more details. Comments-to: Oleg Kiselyov, oleg@ponder.csci.unt.edu, oleg@unt.edu Many-Thanks-To: Tim Clarke, tjc1005@hermes.cam.ac.uk (for inspiration) Explanation: Just fire it up, click on "Go", sit back and enjoy. You may want to adjust elevation, view position, focus, etc. gauges. Hope you'll get some feeling that you're hovering over or flying through the clouds. If you quit the program and start it over again, you'll get different clouds (which might be much better and more interesting to fly around). Right window: a view from above, on the clouds and your plane. Left window: a view from the cockpit. The picture changes as you circle around or alter the view parameters: focus, elevation, etc. The thing flies faster on 24-bit monitors (with Direct color), where CopyBits() doesn't need to do color matching. Sorry about ugly controls: I can't draw at all. Otherwise, I would've drawn my own sliders, rather than ripping and tinkering with system's CDEFs. Source file view_3d.cc in the present submission contains the fullest description (I could come up with) of the 3D rendering technique: with background, equations, pseudocode and the actual code (and tricks with the fixed-point arithmetics: hey, no floating-point numbers are in here). If you need further information or details, please mail me. If you want to see more functionality added, mail me too.