25 #include "StelModule.hpp" 36 class QOpenGLFramebufferObject;
37 class QOpenGLFunctions;
39 class QNetworkAccessManager;
74 friend class StelAppGraphicsWidget;
75 friend class StelRootItem;
88 void init(QSettings* conf);
163 void update(
double deltaTime);
173 void setDevicePixelsPerPixel(
float dppp);
179 void setGlobalScalingRatio(
float r) {globalScalingRatio=r;}
183 void setBaseFontSize(
int s) { baseFontSize=s; }
191 #ifndef DISABLE_SCRIPTING 198 static void initStatic();
199 static void deinitStatic();
275 void visionNightModeChanged(
bool);
276 void colorSchemeChanged(
const QString&);
277 void languageChanged();
288 void handleClick(
class QMouseEvent* event);
290 void handleWheel(
class QWheelEvent* event);
292 bool handleMove(
float x,
float y, Qt::MouseButtons b);
294 void handleKeys(
class QKeyEvent* event);
296 void handlePinch(qreal scale,
bool started);
299 void prepareRenderBuffer();
302 void applyRenderBuffer(quint32 drawFbo=0);
338 QNetworkAccessManager* networkAccessManager;
341 void setupNetworkProxy();
351 #ifndef DISABLE_SCRIPTING 365 float devicePixelsPerPixel;
368 float globalScalingRatio;
371 QTimer * wheelEventTimer;
374 int wheelEventDelta[2];
378 double frameTimeAccum;
381 bool flagNightVision;
383 QSettings* confSettings;
388 static qint64 startMSecs;
389 static float animationScale;
397 int nbDownloadedFiles;
399 qint64 totalDownloadedSize;
404 qint64 totalUsedCacheSize;
406 QList<StelProgressController*> progressControllers;
411 QOpenGLFramebufferObject* renderBuffer;
413 QOpenGLFunctions* gl;
415 bool flagShowDecimalDegrees;
417 bool flagUseAzimuthFromSouth;
418 bool flagUseFormattingOutput;
419 bool flagUseCCSDesignation;
429 #endif // _STELAPP_HPP_ Manage the sky background images, including DSS and deep sky objects images.
void setFlagSouthAzimuthUsage(bool use)
Get flag for using calculation of azimuth from south towards west (instead north towards east) ...
StelScriptMgr & getScriptMgr()
Get the script manager.
StelLocationMgr & getLocationMgr()
Get the Location manager to use for managing stored locations.
StelVideoMgr * getStelVideoMgr()
Get the video manager.
bool getFlagShowDecimalDegrees() const
Get flag for showing decimal degree in various places.
A scriptable way to show videos embedded in the screen.
void setFlagUseFormattingOutput(bool b)
Set flag for using of formatting output for coordinates.
void reportFileDownloadFinished(QNetworkReply *reply)
Report that a download occured.
bool getFlagSouthAzimuthUsage() const
Set flag for using calculation of azimuth from south towards west (instead north towards east) ...
int getBaseFontSize() const
Get the size of font.
void glWindowHasBeenResized(const QRectF &rect)
Call this when the size of the GL window has changed.
void dumpModuleActionPriorities(StelModule::StelModuleActionName actionName)
Dump diagnostics about action call priorities.
float getFps() const
Get the current number of frame per second.
void progressBarRemoved(const StelProgressController *)
Called just before a progress bar is removed.
void initScriptMgr()
Registers all loaded StelModules with the ScriptMgr, and queues starting of the startup script...
StelObjectMgr & getStelObjectMgr()
Get the StelObject manager to use for querying from all stellarium objects.
bool getFlagUseCCSDesignation() const
Get flag for using designations for celestial coordinate systems.
static double getAnimationTime()
Return the scaled time for animated objects.
StelPropertyMgr * getStelPropertyManager()
Return the property manager.
void ensureGLContextCurrent()
Makes sure the correct GL context used for main drawing is made current.
Manage i18n operations such as message translation and date/time localization.
Main class for Stellarium core processing.
Because the core API runs in a different thread to the main program, direct function calls to some cl...
StelModuleMgr & getModuleMgr()
Get the module manager to use for accessing any module loaded in the application. ...
StelTextureMgr & getTextureManager()
Get the texture manager to use for loading textures.
void deinit()
Deinitialize core and all the modules.
Manage the list of available location.
StelApp(StelMainView *parent)
Create and initialize the main Stellarium application.
QNetworkAccessManager * getNetworkAccessManager()
Get the common instance of QNetworkAccessManager used in stellarium.
QString getCurrentStelStyle()
Return the currently used style.
void progressBarAdded(const StelProgressController *)
Called just after a progress bar is added.
Abstract class defining the base interface for all GUIs.
StelMainScriptAPIProxy * getMainScriptAPIProxy()
Get the script API proxy (for signal handling)
void setGui(StelGuiBase *b)
Tell the StelApp instance which GUI is currently being used.
void initPlugIns()
Load and initialize external modules (plugins)
Helper class to send rendered frames to Spout (http://spout.zeal.co/)
StelActionMgr * getStelActionManager()
Get the actions manager to use for managing and editing actions.
void draw()
Draw all registered StelModule in the order defined by the order lists.
void update(double deltaTime)
Update all object according to the deltaTime in seconds.
Allow to apply visual effects on the whole Stellarium viewport.
Manage a collection of StelModules including both core and plugin modules.
QString getViewportEffect() const
Get the type of viewport effect currently used.
void updateI18n()
Update translations, font for GUI and sky everywhere in the program.
Manages the registration of specific object properties with the StelProperty system.
float getGlobalScalingRatio() const
Get the scaling ratio to apply on all display elements, like GUI, text etc.
void quit()
do some cleanup and call QCoreApplication::exit(0)
Reimplement a QGraphicsView for Stellarium.
StelAudioMgr * getStelAudioMgr()
Get the audio manager.
Manage the selection and queries on one or more StelObjects.
StelModuleActionName
Define the possible action for which an order is defined.
Manage scripting in Stellarium.
float getDevicePixelsPerPixel() const
Get the ratio between real device pixel and "Device Independent Pixel".
Maintain the state of a progress bar.
Manage sky cultures for stellarium.
void setVisionModeNight(bool)
Set flag for activating night vision mode.
Manager for StelAction instances. Allows registration of new actions, and finding an existing one by ...
static double getTotalRunTime()
Return the time since when stellarium is running in second.
bool getFlagUseFormattingOutput() const
Get flag for using of formatting output for coordinates.
void setViewportEffect(const QString &effectName)
Define the type of viewport effect to use.
static StelApp & getInstance()
Get the StelApp singleton instance.
virtual ~StelApp()
Deinitialize and destroy the main Stellarium application.
StelSkyCultureMgr & getSkyCultureMgr()
Get the sky cultures manager.
QSettings * getSettings()
Return the main configuration options.
void setFlagUseCCSDesignation(bool b)
Set flag for using designations for celestial coordinate systems.
StelGuiBase * getGui() const
Get the GUI instance implementing the abstract GUI interface.
quint32 getDefaultFBO() const
Returns the default FBO handle, to be used when StelModule instances want to release their own FBOs...
void setFlagShowDecimalDegrees(bool b)
Set flag for showing decimal degree in various places.
Singleton main Stellarium application class.
static QStringList getCommandlineArguments()
Returns all arguments passed on the command line, together with the contents of the STEL_OPTS environ...
StelProgressController * addProgressBar()
Add a progression indicator to the GUI (if applicable).
void aboutToQuit()
Called just before we exit Qt mainloop.
StelCore * getCore()
Get the core of the program.
StelLocaleMgr & getLocaleMgr()
Get the locale manager to use for i18n & date/time localization.
void init(QSettings *conf)
Initialize core and all the modules.
bool getVisionModeNight() const
Get flag for activating night vision mode.