Warning, /education/kstars/doc/dumpmode.docbook is written in an unsupported language. File is not indexed.

0001 <chapter id="dumpmode">
0002 <title>Command-Line mode for Image Generation</title>
0003 <indexterm><primary>Image-dump Mode</primary></indexterm>
0005 <para>
0006 You can use &kstars; to generate an image of the sky
0007 without actually launching the &GUI;
0008 portion of the program.  To use this feature, start
0009 &kstars; from a command prompt using arguments to
0010 specify the filename for the image, as well as the
0011 desired image dimensions:
0013 <cmdsynopsis>
0014 <command>kstars</command>
0015 <arg choice="plain">--dump</arg>
0016 <arg>--filename <replaceable>kstars.png</replaceable></arg>
0017 <arg>--height <replaceable>640</replaceable></arg>
0018 <arg>--width <replaceable>480</replaceable></arg>
0019 <arg>--script <replaceable>myscript.kstars</replaceable></arg>
0020 <arg>--date <replaceable>"4 July 1976
0021 12:30:00"</replaceable></arg>
0022 </cmdsynopsis>
0023 </para>
0024 <para>
0025 If no filename is specified, it generates a file
0026 named <filename>kstars.png</filename>.  It will attempt to
0027 generate an image that matches the extension of your filename.
0028 The following extensions are recognized: <quote>png</quote>,
0029 <quote>jpg</quote>, <quote>jpeg</quote>, <quote>gif</quote>,
0030 <quote>pnm</quote>, and <quote>bmp</quote>.  If the filename
0031 extension is not recognized, it defaults to the
0032 <acronym>PNG</acronym> image type.
0033 </para>
0034 <para>
0035 Likewise, if the image width and height are not specified,
0036 they default to 640 and 480, respectively.
0037 </para>
0038 <para>
0039 By default, &kstars; will read in the options values stored in
0040 your <filename>$KDEHOME/share/config/kstarsrc</filename> file
0041 to determine where the image will be centered, and how it is
0042 rendered.  This means you need to run &kstars; in normal &GUI;
0043 mode, and exit the program when it is set up with the desired
0044 options for the generated images.  This is not very flexible,
0045 so we also provide the ability to execute a &kstars;
0046 &DBus; script to set the scene before
0047 generating the image.  The filename you specify as the
0048 script argument should be a valid &kstars;
0049 &DBus; script, such as one created with the
0050 <link linkend="tool-scriptbuilder">Script Builder Tool</link>.
0051 The script can be used to set where the image is pointing,
0052 set the geographic location, set the time and date, change the
0053 Zoom level, and adjust other view options.  Some of the
0054 &DBus; functions make no sense in non-&GUI;
0055 mode (such as <function>waitForKey()</function>); if these
0056 functions are encountered while parsing the script, they are
0057 simply ignored.
0058 </para>
0059 <para>
0060 By default, &kstars; will use the system CPU time and date for
0061 generating the image.  Alternatively, you may specify a time
0062 and date with the <quote>--date</quote> argument.  You can also
0063 use this argument for specifying the startup date in normal
0064 &GUI; mode.
0065 </para>
0067 </chapter>