Search for usage in LXR

#include <skynode.h>

Inheritance diagram for SkyNode:

Public Member Functions

 SkyNode (SkyObject *skyObject)
void addChildNode (QSGNode *node)
virtual void changePos (QPointF pos)
virtual void hide ()
int hideCount ()
SkyMapLitemap () const
const Projectorprojector ()
virtual void show ()
SkyObjectskyObject () const
virtual void update ()
void update (bool drawLabel)
bool visible ()
- Public Member Functions inherited from QSGTransformNode
const QMatrix4x4matrix () const const
void setMatrix (const QMatrix4x4 &matrix)
- Public Member Functions inherited from QSGNode
void appendChildNode (QSGNode *node)
QSGNodechildAtIndex (int i) const const
int childCount () const const
QSGNodefirstChild () const const
QSGNode::Flags flags () const const
void insertChildNodeAfter (QSGNode *node, QSGNode *after)
void insertChildNodeBefore (QSGNode *node, QSGNode *before)
virtual bool isSubtreeBlocked () const const
QSGNodelastChild () const const
void markDirty (QSGNode::DirtyState bits)
QSGNodenextSibling () const const
QSGNodeparent () const const
void prependChildNode (QSGNode *node)
virtual void preprocess ()
QSGNodepreviousSibling () const const
void removeAllChildNodes ()
void removeChildNode (QSGNode *node)
void setFlag (QSGNode::Flag f, bool enabled)
void setFlags (QSGNode::Flags f, bool enabled)
QSGNode::NodeType type () const const

Public Attributes

SkyOpacityNodem_opacity { nullptr }
- Public Attributes inherited from QSGNode
typedef DirtyState
typedef Flags

Protected Attributes

bool m_drawLabel { false }
int m_hideCount { 0 }
SkyObjectm_skyObject { nullptr }

Additional Inherited Members

- Public Types inherited from QSGNode
enum  DirtyStateBit
enum  Flag
enum  NodeType

Detailed Description

Provides virtual functions for update of coordinates and nodes hiding.

A QSGTransformNode derived class that has to be subclassed by node containers like PlanetNode and PointSourceNode. SkyObject * that is passed as parameter to constructor is used in subclasses to calculate new coordinates in update(). Subclasses have to implement hide() so that each of their child nodes can be hidden.

Artem Fedoskin

Definition at line 27 of file skynode.h.

Constructor & Destructor Documentation

◆ SkyNode()

SkyNode::SkyNode ( SkyObject skyObject)


skyObjectthat is represented on the SkyMapLIte

Definition at line 10 of file skynode.cpp.

Member Function Documentation

◆ changePos()

virtual void SkyNode::changePos ( QPointF  pos)

changes the position of SkyNode on SkyMapLite.

Has to be overridden by the classes that support moving

posnew position

Reimplemented in PlanetNode, LabelNode, PointSourceNode, SatelliteNode, DeepSkyNode, GuideLabelNode, and SupernovaNode.

Definition at line 75 of file skynode.h.

◆ hide()

void SkyNode::hide ( )

hides all child nodes (sets opacity of m_opacity to 0)

Reimplemented in PointSourceNode, PlanetNode, DeepSkyNode, PlanetMoonsNode, SatelliteNode, ConstellationArtNode, SkyPolygonNode, and HorizonNode.

Definition at line 21 of file skynode.cpp.

◆ map()

SkyMapLite* SkyNode::map ( ) const

short function to access SkyMapLite

pointer to instance of SkyMapLite class

Definition at line 45 of file skynode.h.

◆ show()

void SkyNode::show ( )

shows all child nodes (sets opacity of m_opacity to 1)

Definition at line 27 of file skynode.cpp.

◆ skyObject()

SkyObject* SkyNode::skyObject ( ) const

returns SkyObject associated with this SkyNode

pointer to the object of type SkyObject

Definition at line 86 of file skynode.h.

◆ update() [1/2]

virtual void SkyNode::update ( )

Updates coordinate of the object on SkyMapLite.

Reimplemented in LabelNode, PointSourceNode, PlanetNode, GuideLabelNode, PlanetMoonsNode, SatelliteNode, ConstellationArtNode, SupernovaNode, and HorizonNode.

Definition at line 48 of file skynode.h.

◆ update() [2/2]

void SkyNode::update ( bool  drawLabel)

sets m_drawLabel to true if it is needed to be drawn and calls update()

drawLabeltrue of label has to be drawn

Definition at line 33 of file skynode.cpp.

◆ visible()

bool SkyNode::visible ( )
true if object is visible (m_opacity->opacity() != 0) else returns false

Definition at line 44 of file skynode.cpp.

The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Fri Aug 12 2022 04:01:02 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.