MythTV  master
Classes | Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | Private Slots | Private Member Functions | Private Attributes | Friends | List of all members
ImageView Class Referenceabstract

#include <imageview.h>

Inheritance diagram for ImageView:
Inheritance graph
[legend]
Collaboration diagram for ImageView:
Collaboration graph
[legend]

Classes

class  LoadAlbumRunnable
 

Public Member Functions

 ImageView (const ThumbList &itemList, int *pos, int slideShow, int sortorder)
 
ThumbItemgetCurrentItem () const
 
virtual ~ImageView ()
 

Protected Member Functions

virtual void Rotate (int angle)=0
 
virtual void DisplayNext (bool reset, bool loadImage)=0
 
virtual void DisplayPrev (bool reset, bool loadImage)=0
 
virtual void Load (void)=0
 
virtual void SetZoom (float zoom)=0
 
virtual void RegisterEffects (void)=0
 
virtual QString GetRandomEffect (void) const
 
virtual void RunEffect (const QString &effect)=0
 
void UpdateLCD (const ThumbItem *item)
 
QString GetDescriptionStatus (void) const
 
void GetScreenShot (QImage &image, const ThumbItem *item)
 
virtual void AddItems (const ThumbList &itemList)
 
ThumbItemadvanceItem ()
 
ThumbItemretreatItem ()
 

Static Protected Member Functions

static SequenceBaseComposeSlideshowSequence (int slideshow_sequencing)
 

Protected Attributes

QSize m_screenSize {640,480}
 
float m_wmult {1.0F}
 
float m_hmult {1.0F}
 
int m_pos
 
int * m_savedPos {nullptr}
 
int m_movieState {0}
 
float m_zoom {1.0F}
 
bool m_info_show {false}
 
bool m_info_show_short {false}
 
bool m_slideshow_running {false}
 
const int m_slideshow_sequencing
 
int m_slideshow_frame_delay {2}
 
int m_slideshow_frame_delay_state {2000}
 
QTimer * m_slideshow_timer {nullptr}
 
const char * m_slideshow_mode {nullptr}
 
bool m_effect_running {false}
 
int m_effect_current_frame {0}
 
QString m_effect_method
 
QMap< QString, QString > m_effect_map
 
bool m_effect_random {false}
 

Private Slots

 Q_DECLARE_TR_FUNCTIONS (ImageView)
 

Private Member Functions

void FinishLoading ()
 
double GetSeasonalWeight (ThumbItem *item)
 This method calculates a weight for the item based on how closely it was taken to the current time of year. More...
 

Private Attributes

LoadAlbumRunnablem_loaderRunnable {nullptr}
 
LoadAlbumListener m_listener
 
MThreadm_loaderThread {nullptr}
 
QWaitCondition m_imagesLoaded
 
QMutex m_itemListLock
 
ThumbList m_itemList
 
SequenceBasem_slideshow_sequence {nullptr}
 
bool m_finishedLoading {false}
 

Friends

class LoadAlbumListener
 

Detailed Description

Definition at line 53 of file imageview.h.

Constructor & Destructor Documentation

◆ ImageView()

ImageView::ImageView ( const ThumbList itemList,
int *  pos,
int  slideShow,
int  sortorder 
)

Definition at line 80 of file imageview.cpp.

◆ ~ImageView()

ImageView::~ImageView ( )
virtual

Definition at line 161 of file imageview.cpp.

Member Function Documentation

◆ Q_DECLARE_TR_FUNCTIONS

ImageView::Q_DECLARE_TR_FUNCTIONS ( ImageView  )
privateslot

◆ getCurrentItem()

ThumbItem * ImageView::getCurrentItem ( ) const

◆ ComposeSlideshowSequence()

SequenceBase * ImageView::ComposeSlideshowSequence ( int  slideshow_sequencing)
staticprotected

Definition at line 191 of file imageview.cpp.

◆ Rotate()

virtual void ImageView::Rotate ( int  angle)
protectedpure virtual

Implemented in GLSingleView, and SingleView.

◆ DisplayNext()

virtual void ImageView::DisplayNext ( bool  reset,
bool  loadImage 
)
protectedpure virtual

Implemented in GLSingleView, and SingleView.

◆ DisplayPrev()

virtual void ImageView::DisplayPrev ( bool  reset,
bool  loadImage 
)
protectedpure virtual

Implemented in GLSingleView, and SingleView.

◆ Load()

virtual void ImageView::Load ( void  )
protectedpure virtual

Implemented in GLSingleView, and SingleView.

◆ SetZoom()

virtual void ImageView::SetZoom ( float  zoom)
protectedpure virtual

Implemented in GLSingleView, and SingleView.

◆ RegisterEffects()

virtual void ImageView::RegisterEffects ( void  )
protectedpure virtual

Implemented in GLSingleView, and SingleView.

◆ GetRandomEffect()

QString ImageView::GetRandomEffect ( void  ) const
protectedvirtual

◆ RunEffect()

virtual void ImageView::RunEffect ( const QString &  effect)
protectedpure virtual

Implemented in GLSingleView, and SingleView.

◆ UpdateLCD()

void ImageView::UpdateLCD ( const ThumbItem item)
protected

◆ GetDescriptionStatus()

QString ImageView::GetDescriptionStatus ( void  ) const
protected

Definition at line 240 of file imageview.cpp.

Referenced by GLSingleView::createTexInfo(), and SingleView::paintEvent().

◆ GetScreenShot()

void ImageView::GetScreenShot ( QImage &  image,
const ThumbItem item 
)
protected

Definition at line 248 of file imageview.cpp.

Referenced by SingleView::paintEvent(), and GLSingleView::paintGL().

◆ AddItems()

void ImageView::AddItems ( const ThumbList itemList)
protectedvirtual

Definition at line 268 of file imageview.cpp.

Referenced by ImageView().

◆ advanceItem()

ThumbItem * ImageView::advanceItem ( )
protected

◆ retreatItem()

ThumbItem * ImageView::retreatItem ( )
protected

Definition at line 305 of file imageview.cpp.

Referenced by SingleView::DisplayPrev(), and GLSingleView::DisplayPrev().

◆ FinishLoading()

void ImageView::FinishLoading ( )
private

Definition at line 312 of file imageview.cpp.

Referenced by ImageView().

◆ GetSeasonalWeight()

double ImageView::GetSeasonalWeight ( ThumbItem item)
private

This method calculates a weight for the item based on how closely it was taken to the current time of year.

This means that New Year's pictures will be displayed very frequently on every New Year's, and that anniversary pictures will be favored again every anniversary. The weights are chosen using a beta distribution with a tunable shape parameter.

Definition at line 326 of file imageview.cpp.

Referenced by AddItems().

Friends And Related Function Documentation

◆ LoadAlbumListener

friend class LoadAlbumListener
friend

Definition at line 88 of file imageview.h.

Member Data Documentation

◆ m_screenSize

QSize ImageView::m_screenSize {640,480}
protected

◆ m_wmult

float ImageView::m_wmult {1.0F}
protected

Definition at line 94 of file imageview.h.

Referenced by ImageView(), and SingleView::paintEvent().

◆ m_hmult

float ImageView::m_hmult {1.0F}
protected

Definition at line 95 of file imageview.h.

Referenced by ImageView(), and SingleView::paintEvent().

◆ m_pos

int ImageView::m_pos
protected

◆ m_savedPos

int* ImageView::m_savedPos {nullptr}
protected

Definition at line 97 of file imageview.h.

Referenced by ~ImageView().

◆ m_movieState

int ImageView::m_movieState {0}
protected

◆ m_zoom

float ImageView::m_zoom {1.0F}
protected

◆ m_info_show

bool ImageView::m_info_show {false}
protected

◆ m_info_show_short

bool ImageView::m_info_show_short {false}
protected

◆ m_slideshow_running

bool ImageView::m_slideshow_running {false}
protected

◆ m_slideshow_sequencing

const int ImageView::m_slideshow_sequencing
protected

Definition at line 106 of file imageview.h.

Referenced by AddItems(), ImageView(), and ImageView::LoadAlbumRunnable::run().

◆ m_slideshow_frame_delay

int ImageView::m_slideshow_frame_delay {2}
protected

◆ m_slideshow_frame_delay_state

int ImageView::m_slideshow_frame_delay_state {2000}
protected

◆ m_slideshow_timer

QTimer* ImageView::m_slideshow_timer {nullptr}
protected

◆ m_slideshow_mode

const char* ImageView::m_slideshow_mode {nullptr}
protected

Definition at line 110 of file imageview.h.

Referenced by GetDescriptionStatus(), and ImageView().

◆ m_effect_running

bool ImageView::m_effect_running {false}
protected

◆ m_effect_current_frame

int ImageView::m_effect_current_frame {0}
protected

◆ m_effect_method

QString ImageView::m_effect_method
protected

◆ m_effect_map

QMap<QString,QString> ImageView::m_effect_map
protected

◆ m_effect_random

bool ImageView::m_effect_random {false}
protected

◆ m_loaderRunnable

LoadAlbumRunnable* ImageView::m_loaderRunnable {nullptr}
private

Definition at line 123 of file imageview.h.

Referenced by ImageView(), and ~ImageView().

◆ m_listener

LoadAlbumListener ImageView::m_listener
private

Definition at line 124 of file imageview.h.

Referenced by ImageView().

◆ m_loaderThread

MThread* ImageView::m_loaderThread {nullptr}
private

Definition at line 125 of file imageview.h.

Referenced by ImageView(), and ~ImageView().

◆ m_imagesLoaded

QWaitCondition ImageView::m_imagesLoaded
private

Definition at line 126 of file imageview.h.

Referenced by AddItems(), FinishLoading(), and ImageView().

◆ m_itemListLock

QMutex ImageView::m_itemListLock
mutableprivate

◆ m_itemList

ThumbList ImageView::m_itemList
private

Definition at line 129 of file imageview.h.

Referenced by AddItems(), advanceItem(), getCurrentItem(), ImageView(), retreatItem(), and UpdateLCD().

◆ m_slideshow_sequence

SequenceBase* ImageView::m_slideshow_sequence {nullptr}
private

Definition at line 130 of file imageview.h.

Referenced by AddItems(), advanceItem(), ImageView(), retreatItem(), and ~ImageView().

◆ m_finishedLoading

bool ImageView::m_finishedLoading {false}
private

Definition at line 131 of file imageview.h.

Referenced by FinishLoading(), and ImageView().


The documentation for this class was generated from the following files: