PLANET CREATOR 1.02
------------------------------------------------------------------------------
by Krischan www.extrasolar.de



License Agreement
---------------------------------------------------------------------------
Copyright (c) 2016, Christian Hart. All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:

- Redistributions of source code must retain the above copyright notice,
  this list of conditions and the following disclaimer.

- Redistributions in binary form must reproduce the above copyright notice,
  this list of conditions and the following disclaimer in the documentation
  and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION). HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
DAMAGE.



Credits
---------------------------------------------------------------------------
Uses some textures from "The Celestia Motherlode" as base rawmaps
http://www.celestiamotherlode.net

Uses free Icons from "Findicons" (findicons.com) Themes:

- Gnome 2.18 Icon Theme
  http://findicons.com/pack/1722/gnome_2_18_icon_theme
  
- GNOME Desktop
  http://findicons.com/pack/753/gnome_desktop

- Kids
  http://findicons.com/pack/85/kids

- Vista Style Arrow
  http://findicons.com/pack/2128/vista_style_arrow

- Tango
  http://findicons.com/pack/1150/tango

- Human-O2
  http://findicons.com/pack/1035/human_o2

- Siena
  http://findicons.com/pack/1681/siena

- Oxygen
  http://findicons.com/pack/2166/oxygen

- Pretty Office Icon Set Part
  http://findicons.com/pack/2472/pretty_office_icon_set_part_7

Uses free Icons from "Fugue Icons" (http://p.yusukekamiyamane.com)

Blitz Appicon from BLIDE (http://www.blide.org)



GENERAL INFO
---------------------------------------------------------------------------
With the Blitzmax application Planet Creator, a free piece of software, you can
create your own planets on the fly now. You can create wallpapers, fly
around or create whole texture sets for your own 3D scene or other programs
like Celestia. It is written in BlitzMax (www.blitzbasic.com) and uses the
modules "MiniB3D" and "MaxGUI". Planet Creator takes one or two RAW basemaps,
blends them together with a pseudorandom noisemap, applies a custom gradient
and does some finetuning work like Emboss filter, add Polar caps or create
a night map. The final planet gets calculated in a few seconds only and can be
previewed together with clouds, atmosphere and glow in a nice milkyway / sun
environment. There is a complete GUI included and you can choose from 24
predefined presets for all different types of planets very easy.



SPEED VS. RANDOMNESS
---------------------------------------------------------------------------
The planets start looking similar when you create thousands of them. But the
purpose of Planet Creator is more realtime, to get exiting results in a few
seconds but not preprocess all of them and waste a lot of space. I call it
"semirandom". How to use the TPlanet type in your own games or programs is
explained in the small example "simpledemo.bmx". And I tried to comment the
whole source.



CREATE YOUR OWN PRESETS
---------------------------------------------------------------------------
To alter a preset or create your own planet feel free to edit the two files
"palette.ini" and "presets.ini" in the config folder. In the presets.ini there
is a [Default] Template with ALL changeable settings included. ALL planets use
these settings until a setting is overwritten in a custom preset. You can even
add your own raw maps (use Photoshop RAW format here) but Planet Creator is not
fail safe and will only use predefined filenames until you alter the source
code yourself. And the INI loader is not very intelligent at this time, there is
a nasty bug - try to move the setting up/downwards in the section to fix it if
you run into it.



COMPILE PLANET CREATOR BY YOURSELF
---------------------------------------------------------------------------
Planet Creator has been compiled with MiniB3D 0.54. If you want to recompile it
take a look at the "blitzmax" folder coming with Planet Creator, I altered three
files for my own use so it is a good idea to compare them with your files first
or even overwrite your files with these versions.



FLIGHT MODES INFORMATION
---------------------------------------------------------------------------
In the freeflight mode you can increase the speed with the right SHIFT key.
Both in freeflight and normal view mode use the left Mousebutton to start the
view / flight and use the Arrow keys to increase/decrease speed and rotate.



ADDITIONAL TOOLS
---------------------------------------------------------------------------
Together with the convertmaps tool I added two additional tools in the tools/
folder. "createbasemap" creates a new continental basemap I used as "plate"
which is nice to separate details and make the planet more continental. The
other tool "createpalette" is used to create your own palette sets but it is
tricky to use. To create your own palette you should use a PNG image with a
fixed palette (for example: 16 colors). The tool will extract these colors
and output a text file you can use in the palette.ini to tweak the colors of
a new planet. As example I included Io, a jupiter moon and the output of it.



KEYBOARD SHORTCUTS
---------------------------------------------------------------------------
ESCAPE      End Program
SPACE       Creates a new planet from the current Template preset
BACKSPACE   Resets the scene
RETURN      Saves a screenshot (Standard: 1920x1200px) to the "output/" folder
TAB         Toggles Minimap size (small / fullscreen)

E           Saves all textures to the "output/" folder
W           Toggles Wireframe mode
Q           Toggles Minimap
L           Toggles Minimap Position Tracer (inactive by now)
I           Toggles Information display about current planet
V           Activates Planet View mode
F           Activates Planet Freeflight mode

C           Toggles Clouds
S           Toggles Cloudshadows
N           Toggles Nightmap (Citylights or molten/glowing Nightside)
G           Toggles Atmosphere Glow
A           Toggles Atmosphere Effect
M           Toggles Shadowmap
R           Toggles Rings
D           Toggles Detailmap
T           Toggles Planet Rotation

1           Level of Detail: 2048x1024
2           Level of Detail: 1024x512
3           Level of Detail: 512x256

4           Saves a 4:3 screenshot with 1024x768 Pixels
5           Saves a 4:3 screenshot with 1280x1024 Pixels

6           Saves a wide screenshot with 1280x800 Pixels
7           Saves a wide screenshot with 1366x768 Pixels
8           Saves a wide screenshot with 1600x900 Pixels
9           Saves a wide screenshot with 1920x1200 Pixels (Default size)



A final request by the author:
---------------------------------------------------------------------------
The author would be happy if you let him know what you created using
PlanetCreator, just out of curiosity and asks you to improve the code and share
the improvements with the BlitzBasic community again like he did before. There
is a lot of work in this project and the author decided to give it away for
free, so set a good example if you are willing to.

But these two conditions are no prerequisites for using this code in your
own free or commercial applications. The decision is up to you.

You can contact Krischan at www.extrasolar.de, use the contact form there.