1 #+TITLE: QBasicApps - collection of applications mostly written in MS QBasic for DOS environment
4 - [[http://www2.svjatoslav.eu/gitweb/?p=qbasicapps.git;a=snapshot;h=HEAD;sf=tgz][download latest snapshot]]
6 - This program is free software; you can redistribute it and/or modify
7 it under the terms of version 3 of the [[https://www.gnu.org/licenses/lgpl.html][GNU Lesser General Public
8 License]] or later as published by the Free Software Foundation.
12 - Homepage: http://svjatoslav.eu
13 - Email: mailto://svjatoslav@svjatoslav.eu
15 - [[http://www.svjatoslav.eu/programs.jsp][other applications hosted at svjatoslav.eu]]
19 Parses scene definition language and creates 3D world based on
20 it. Result will be in a [[https://en.wikipedia.org/wiki/Wavefront_.obj_file][wavefront obj file]], witch can be then
21 visualized using external renderer.
23 Basic concept of defining scene is:
24 - Simple and primitive objects are created on point and polygon level.
25 - More complex ones can be created my combinig already existing ones,
26 while applying various transformations on them.
28 Objects with all its subobjects can be rotated, mirrored or resized
29 omong any axis. Generator has built in cache for data input and output
30 to minimize file access.
33 | software | preferred version |
34 |----------+-------------------|
38 + Unpack ZIP file in any folder.
39 + update include path inside bin/3dparse.bas
42 + 3dparse.bas - 3D generator main executable
43 + city1.3d - city with square-like buildings
44 + city2.3d - city with hexangular buildings
45 + result.mtl - shared material library
46 + *.bat - quick launch scripts
48 + include - 3D objects used to compose the scene
49 * Scene description language
60 defines new polygon, p4 may be unused
64 displays warning message, and wait for key
73 selects random material from list
75 : obj object xz45 xy20 x+3 y*2
76 includes sub object, can be rotated moved or resized, across X Y Z. If
77 object name begin vith ~ then it will be loaded from current
78 directory. if object name ends with ~ then object will be parsed
79 directly from file, and not chached, to allow loading of greater than
86 select random command to execute, ^ will be converted to spaces.
92 specify output file name, must be first command
94 : set variable contents
95 set variable contents, variable must be number, contents can be
96 string. max variables is 100. first is 0.
98 : anycommand %1 anything
99 inserts variable 1 contents info line
101 : cmp flag string1 string2
102 compares strings, and inserts TRUE to flag, if they are equal, else inserts FALSE. max 9 falgs, 0 first. Each subobject has its own flags.
105 executes command if flag is true.
107 exapmle: ?3 obj car z*2 xy45
110 dummy function, does notheing
113 Make sure you have QB binaries in your PATH. Execute
117 to generate example cities. After parsing is finished, appropriate
118 *.obj files will appear in the bin directory holding generated scene.
119 Visualize scene with your favourite renderer.
121 Download Blender files:
123 |------------------------+--------|
124 | [[file:rectangular city.blend][rectangular city.blend]] | 3.6 MB |
125 | [[file:hexagonal city.blend][hexagonal city.blend]] | 21 MB |
127 They were produced by importing generated [[https://en.wikipedia.org/wiki/Wavefront_.obj_file][wavefront obj files]] into
128 [[https://www.blender.org/][Blender]].
131 [[file:rectangular city, 1.jpeg]]
133 [[file:rectangular city, 2.jpeg]]
135 [[file:rectangular city, 3.jpeg]]
137 [[file:hexagonal city, 1.jpeg]]
139 [[file:hexagonal city, 2.jpeg]]
141 [[file:hexagonal city, 3.jpeg]]
143 * (document settings) :noexport:
144 ** use dark style for TWBS-HTML exporter
145 #+HTML_HEAD: <link href="https://bootswatch.com/4/darkly/bootstrap.min.css" rel="stylesheet">
146 #+HTML_HEAD: <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
147 #+HTML_HEAD: <script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.1/js/bootstrap.min.js"></script>"
148 #+HTML_HEAD: <style type="text/css">
149 #+HTML_HEAD: footer {background-color: #111 !important;}
150 #+HTML_HEAD: pre {background-color: #111; color: #ccc;}
151 #+HTML_HEAD: </style>