StelMainScriptAPI.hpp   StelMainScriptAPI.hpp 
skipping to change at line 109 skipping to change at line 109
//! @param name the name of the object to select (english) //! @param name the name of the object to select (english)
//! If the name is "", any currently selected objects will be //! If the name is "", any currently selected objects will be
//! de-selected. //! de-selected.
//! @param pointer whether or not to have the selection pointer enab led //! @param pointer whether or not to have the selection pointer enab led
void selectObjectByName(const QString& name, bool pointer=false); void selectObjectByName(const QString& name, bool pointer=false);
//! Fetch a map with data about an object's position, magnitude and so on //! Fetch a map with data about an object's position, magnitude and so on
//! @param name is the English name of the object for which data wil l be //! @param name is the English name of the object for which data wil l be
//! returned. //! returned.
//! @return a map of object data. Keys: //! @return a map of object data. Keys:
//! - altitude : altitude angle in decimal degrees //! - altitude : apparent altitude angle in decimal degrees
//! - azimuth : azimuth angle in decimal degrees //! - azimuth : apparent azimuth angle in decimal degrees
//! - altitude-geometric : geometric altitude angle in decimal degre
es
//! - azimuth-geometric : geometric azimuth angle in decimal degrees
//! - ra : right ascension angle (current date frame) in decimal deg rees //! - ra : right ascension angle (current date frame) in decimal deg rees
//! - dec : declenation angle in (current date frame) decimal degree s //! - dec : declenation angle in (current date frame) decimal degree s
//! - raJ2000 : right ascension angle (J2000 frame) in decimal degre es //! - raJ2000 : right ascension angle (J2000 frame) in decimal degre es
//! - decJ2000 : declenation angle in (J2000 frame) decimal degrees //! - decJ2000 : declenation angle in (J2000 frame) decimal degrees
QVariantMap getObjectPosition(const QString& name); QVariantMap getObjectPosition(const QString& name);
//! Clear the display options, setting a "standard" view. //! Clear the display options, setting a "standard" view.
//! Preset states: //! Preset states:
//! - natural : azimuthal mount, atmosphere, landscape, //! - natural : azimuthal mount, atmosphere, landscape,
//! no lines, labels or markers //! no lines, labels or markers
skipping to change at line 204 skipping to change at line 206
//! Set the location by the name of the location. //! Set the location by the name of the location.
//! @param id the location ID as it would be found in the database //! @param id the location ID as it would be found in the database
//! of locations - do a search in the Location window to see what //! of locations - do a search in the Location window to see what
//! where is. e.g. "York, UnitedKingdom". //! where is. e.g. "York, UnitedKingdom".
//! @param duration the number of seconds to take to move location. //! @param duration the number of seconds to take to move location.
void setObserverLocation(const QString id, float duration=1.); void setObserverLocation(const QString id, float duration=1.);
//! Get the ID of the current observer location. //! Get the ID of the current observer location.
QString getObserverLocation(); QString getObserverLocation();
//! Get the info of the current observer location.
//! @return a map of object data. Keys:
//! - altitude : altitude in meters
//! - longitude : longitude in decimal degrees
//! - latitude : latitude in decimal degrees
//! - planet : name of planet
//! - location : city and country
QVariantMap getObserverLocationInfo();
//! Save a screenshot. //! Save a screenshot.
//! @param prefix the prefix for the file name to use //! @param prefix the prefix for the file name to use
//! @param dir the path of the directory to save the screenshot in. If //! @param dir the path of the directory to save the screenshot in. If
//! none is specified, the default screenshot directory will be used . //! none is specified, the default screenshot directory will be used .
//! @param invert whether colors have to be inverted in the output i mage //! @param invert whether colors have to be inverted in the output i mage
void screenshot(const QString& prefix, bool invert=false, const QStr ing& dir=""); void screenshot(const QString& prefix, bool invert=false, const QStr ing& dir="");
//! Show or hide the GUI (toolbars). Note this only applies to GUI plugins which //! Show or hide the GUI (toolbars). Note this only applies to GUI plugins which
//! provide the public slot "setGuiVisible(bool)". //! provide the public slot "setGuiVisible(bool)".
//! @param b if true, show the GUI, if false, hide the GUI. //! @param b if true, show the GUI, if false, hide the GUI.
skipping to change at line 359 skipping to change at line 370
double minRes=2.5, double maxBrigh t=14, bool visible=true); double minRes=2.5, double maxBrigh t=14, bool visible=true);
//! Convenience function which allows loading of a sky image based o n a //! Convenience function which allows loading of a sky image based o n a
//! central coordinate, angular size and rotation. Parameters are t he same //! central coordinate, angular size and rotation. Parameters are t he same
//! as the version of this function which takes double values for th e //! as the version of this function which takes double values for th e
//! ra and dec, except here text expressions of angles may be used. //! ra and dec, except here text expressions of angles may be used.
void loadSkyImage(const QString& id, const QString& filename, void loadSkyImage(const QString& id, const QString& filename,
const QString& ra, const QString& dec, double angSize, double rotation, const QString& ra, const QString& dec, double angSize, double rotation,
double minRes=2.5, double maxBrigh t=14, bool visible=true); double minRes=2.5, double maxBrigh t=14, bool visible=true);
//! Load an image which will have sky coordinates.
//! @param id a string ID to be used when referring to this
//! image (e.g. when changing the displayed status or deleting
//! it.
//! @param filename the file name of the image. If a relative
//! path is specified, "scripts/" will be prefixed before the
//! image is searched for using StelFileMgr.
//! @param alt0 The altitude angle of the first corner of the image
in degrees
//! @param azi0 The azimuth angle of the first corner of the image i
n degrees
//! @param alt1 The altitude angle of the second corner of the image
in degrees
//! @param azi1 The azimuth angle of the second corner of the image
in degrees
//! @param alt2 The altitude angle of the third corner of the image
in degrees
//! @param azi2 The azimuth angle of the third corner of the image i
n degrees
//! @param alt3 The altitude angle of the fourth corner of the image
in degrees
//! @param azi3 The azimuth angle of the fourth corner of the image
in degrees
//! @param minRes The minimum resolution setting for the image
//! @param maxBright The maximum brightness setting for the image
//! @param visible The initial visibility of the image
void loadSkyImageAltAz(const QString& id, const QString& filename,
double alt0, double azi0,
double alt1, double azi1,
double alt2, double azi2,
double alt3, double azi3,
double minRes=2.5, double maxBrigh
t=14, bool visible=true);
//! Convenience function which allows loading of a sky image based o
n a
//! central coordinate, angular size and rotation.
//! @param id a string ID to be used when referring to this
//! image (e.g. when changing the displayed status or deleting it.
//! @param filename the file name of the image. If a relative
//! path is specified, "scripts/" will be prefixed before the
//! image is searched for using StelFileMgr.
//! @param alt The altitude angle of the center of the image in degr
ees
//! @param azi The azimuth angle of the center of the image in degre
es
//! @param angSize The angular size of the image in arc minutes
//! @param rotation The clockwise rotation angle of the image in deg
rees
//! @param minRes The minimum resolution setting for the image
//! @param maxBright The maximum brightness setting for the image
//! @param visible The initial visibility of the image
void loadSkyImageAltAz(const QString& id, const QString& filename,
double alt, double azi, double ang
Size, double rotation,
double minRes=2.5, double maxBrigh
t=14, bool visible=true);
//! Remove a SkyImage. //! Remove a SkyImage.
//! @param id the ID of the image to remove. //! @param id the ID of the image to remove.
void removeSkyImage(const QString& id); void removeSkyImage(const QString& id);
//! Load a sound from a file. //! Load a sound from a file.
//! @param filename the name of the file to load. //! @param filename the name of the file to load.
//! @param id the identifier which will be used to refer to the soun d //! @param id the identifier which will be used to refer to the soun d
//! when calling playSound, pauseSound, stopSound and dropSound. //! when calling playSound, pauseSound, stopSound and dropSound.
void loadSound(const QString& filename, const QString& id); void loadSound(const QString& filename, const QString& id);
skipping to change at line 389 skipping to change at line 443
//! sound to the start so that subsequent playSound calls will //! sound to the start so that subsequent playSound calls will
//! start from the beginning. //! start from the beginning.
//! @param id the identifier used when loadSound was called //! @param id the identifier used when loadSound was called
void stopSound(const QString& id); void stopSound(const QString& id);
//! Drop a sound from memory. You should do this before the end //! Drop a sound from memory. You should do this before the end
//! of your script. //! of your script.
//! @param id the identifier used when loadSound was called //! @param id the identifier used when loadSound was called
void dropSound(const QString& id); void dropSound(const QString& id);
//! Load a video from a file.
//! @param filename the name of the file to load.
//! @param id the identifier which will be used to refer to the vide
o
//! when calling playVideo, pauseVideo, stopVideo and dropVideo.
//! @param x the x-coordinate for the video widget.
//! @param y the y-coordinate for the video widget.
//! @param show the visibility state for the video.
//! @param alpha the initial alpha value of the video.
void loadVideo(const QString& filename, const QString& id, float x,
float y, bool show, float alpha);
//! Play a video which has previously been loaded with loadVideo
//! @param id the identifier used when loadVideo was called
void playVideo(const QString& id);
//! Pause a video which is playing. Subsequent playVideo calls will
//! resume playing from the position in the file when it was paused.
//! @param id the identifier used when loadVideo was called
void pauseVideo(const QString& id);
//! Stop a video from playing. This resets the position in the
//! video to the start so that subsequent playVideo calls will
//! start from the beginning.
//! @param id the identifier used when loadVideo was called
void stopVideo(const QString& id);
//! Drop a video from memory. You should do this before the end
//! of your script.
//! @param id the identifier used when loadVideo was called
void dropVideo(const QString& id);
//! Seeks a video to the requested time.
//! @param id the identifier used when loadVideo was called
//! @param ms the time in milliseconds from the start of the media.
void seekVideo(const QString& id, qint64 ms);
//! Sets the position of the video widget.
//! @param id the identifier used when loadVideo was called
//! @param x the new x-coordinate for the video.
//! @param y the new y-coordinate for the video.
void setVideoXY(const QString& id, float x, float y);
//! Set the alpha value of a video when visible.
//! @param id the identifier used when loadVideo was called
//! @param alpha the new alpha value to set.
void setVideoAlpha(const QString& id, float alpha);
//! Resize the video widget to the specified width, height.
//! @param id the identifier used when loadVideo was called
//! @param w the new width for the widget.
//! @param h the new height for the widget.
void resizeVideo(const QString& id, float w, float h);
//! Set the visibility state of a video.
//! @param id the identifier used when loadVideo was called
//! @param show the new visible state of the video.
void showVideo(const QString& id, bool show);
//! Get the screen width in pixels. //! Get the screen width in pixels.
//! @return The screen width in pixels //! @return The screen width in pixels
int getScreenWidth(); int getScreenWidth();
//! Get the screen height in pixels. //! Get the screen height in pixels.
//! @return The screen height in pixels //! @return The screen height in pixels
int getScreenHeight(); int getScreenHeight();
//! Get the script execution rate as a multiple of normal execution speed //! Get the script execution rate as a multiple of normal execution speed
//! @return the current script execution rate. //! @return the current script execution rate.
double getScriptRate(); double getScriptRate();
//! Set the script execution rate as a multiple of normal execution speed //! Set the script execution rate as a multiple of normal execution speed
//! @param r the multiple of the normal script execution speed, i.e. //! @param r the multiple of the normal script execution speed, i.e.
//! if 5 is passed the script will execute 5 times faster than it wo uld //! if 5 is passed the script will execute 5 times faster than it wo uld
//! if the script rate was 1. //! if the script rate was 1.
void setScriptRate(double r); void setScriptRate(double r);
//! Pause the currently running script. Note that you may need to us
e
//! the key '6' or the GUI to resume script execution.
void pauseScript();
//! Set the amount of selected object information to display //! Set the amount of selected object information to display
//! @param level can be "AllInfo", "ShortInfo", "None" //! @param level can be "AllInfo", "ShortInfo", "None"
void setSelectedObjectInfo(const QString& level); void setSelectedObjectInfo(const QString& level);
//! Stop the script //! Stop the script
void exit(); void exit();
//! Close Stellarium //! Close Stellarium
void quitStellarium(); void quitStellarium();
skipping to change at line 435 skipping to change at line 550
void setAppLanguage(QString langCode); void setAppLanguage(QString langCode);
//! Get the current sky language. //! Get the current sky language.
//! @return two letter language code, e.g. "en", or "de" and so on. //! @return two letter language code, e.g. "en", or "de" and so on.
QString getSkyLanguage(); QString getSkyLanguage();
//! Set the current sky language. //! Set the current sky language.
//! @param langCode two letter language code, e.g. "en", or "de". //! @param langCode two letter language code, e.g. "en", or "de".
void setSkyLanguage(QString langCode); void setSkyLanguage(QString langCode);
//! Go to defaults position and direction of view
void goHome();
//! For use in setDate and waitFor //! For use in setDate and waitFor
//! For parameter descriptions see setDate(). //! For parameter descriptions see setDate().
//! @returns Julian day. //! @returns Julian day.
double jdFromDateString(const QString& dt, const QString& spec); double jdFromDateString(const QString& dt, const QString& spec);
signals: signals:
void requestLoadSkyImage(const QString& id, const QString& filename, void requestLoadSkyImage(const QString& id, const QString& filename,
double c1, double c 2, double c1, double c 2,
double c3, double c 4, double c3, double c 4,
double c5, double c 6, double c5, double c 6,
double c7, double c 8, double c7, double c 8,
double minRes, doub le maxBright, bool visible); double minRes, doub le maxBright, bool visible);
void requestLoadSkyImageAltAz(const QString& id, const QString& file
name,
double c1, double c
2,
double c3, double c
4,
double c5, double c
6,
double c7, double c
8,
double minRes, doub
le maxBright, bool visible);
void requestRemoveSkyImage(const QString& id); void requestRemoveSkyImage(const QString& id);
void requestLoadSound(const QString& filename, const QString& id); void requestLoadSound(const QString& filename, const QString& id);
void requestPlaySound(const QString& id); void requestPlaySound(const QString& id);
void requestPauseSound(const QString& id); void requestPauseSound(const QString& id);
void requestStopSound(const QString& id); void requestStopSound(const QString& id);
void requestDropSound(const QString& id); void requestDropSound(const QString& id);
void requestLoadVideo(const QString& filename, const QString& id, fl
oat x, float y, bool show, float alpha);
void requestPlayVideo(const QString& id);
void requestPauseVideo(const QString& id);
void requestStopVideo(const QString& id);
void requestDropVideo(const QString& id);
void requestSeekVideo(const QString& id, qint64 ms);
void requestSetVideoXY(const QString& id, float x, float y);
void requestSetVideoAlpha(const QString& id, float alpha);
void requestResizeVideo(const QString& id, float w, float h);
void requestShowVideo(const QString& id, bool show);
void requestSetNightMode(bool b); void requestSetNightMode(bool b);
void requestSetProjectionMode(QString id); void requestSetProjectionMode(QString id);
void requestSetSkyCulture(QString id); void requestSetSkyCulture(QString id);
void requestSetDiskViewport(bool b); void requestSetDiskViewport(bool b);
void requestExit(); void requestExit();
void requestSetHomePosition();
}; };
#endif // _STELMAINSCRIPTAPI_HPP_ #endif // _STELMAINSCRIPTAPI_HPP_
 End of changes. 9 change blocks. 
2 lines changed or deleted 164 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/