File indexing completed on 2025-03-09 03:52:08
0001 /* ============================================================ 0002 * 0003 * This file is a part of digiKam project 0004 * https://www.digikam.org 0005 * 0006 * Date : 2007-11-14 0007 * Description : a presentation tool. 0008 * 0009 * SPDX-FileCopyrightText: 2007-2009 by Valerio Fuoglio <valerio dot fuoglio at gmail dot com> 0010 * SPDX-FileCopyrightText: 2012-2024 by Gilles Caulier <caulier dot gilles at gmail dot com> 0011 * 0012 * Parts of this code are based on 0013 * smoothslidesaver by Carsten Weinhold <carsten dot weinhold at gmx dot de> 0014 * and slideshowgl by Renchi Raju <renchi dot raju at gmail dot com> 0015 * 0016 * SPDX-License-Identifier: GPL-2.0-or-later 0017 * 0018 * ============================================================ */ 0019 0020 #ifndef DIGIKAM_PRESENTATION_KB_PRIVATE_H 0021 #define DIGIKAM_PRESENTATION_KB_PRIVATE_H 0022 0023 #include "presentationkb.h" 0024 0025 // Local includes 0026 0027 #include "digikam_config.h" 0028 #include "digikam_debug.h" 0029 #include "presentationcontainer.h" 0030 #include "kbimageloader.h" 0031 #include "kbeffect.h" 0032 0033 // OpenGL headers is not included automatically with ARM targets 0034 0035 #ifdef Q_PROCESSOR_ARM 0036 # include <GL/gl.h> 0037 #endif 0038 0039 #ifdef HAVE_MEDIAPLAYER 0040 # include "presentationaudiowidget.h" 0041 #endif 0042 0043 using namespace Digikam; 0044 0045 namespace DigikamGenericPresentationPlugin 0046 { 0047 0048 class KBImageLoader; 0049 class ScreenProperties; 0050 class PresentationAudioWidget; 0051 0052 class Q_DECL_HIDDEN PresentationKB::Private 0053 { 0054 0055 public: 0056 0057 explicit Private() 0058 : deskX (0), 0059 deskY (0), 0060 deskWidth (0), 0061 deskHeight (0), 0062 endTexture (nullptr), 0063 imageLoadThread (nullptr), 0064 mouseMoveTimer (nullptr), 0065 timer (nullptr), 0066 haveImages (true), 0067 effect (nullptr), 0068 numKBEffectRepeated (0), 0069 initialized (false), 0070 step (0.0), 0071 stepSameSpeed (0.0), 0072 endOfShow (false), 0073 showingEnd (false), 0074 delay (0), 0075 disableFadeInOut (false), 0076 disableCrossFade (false), 0077 enableSameSpeed (false), 0078 forceFrameRate (0), 0079 sharedData (nullptr), 0080 playbackWidget (nullptr) 0081 { 0082 zoomIn = (QRandomGenerator::global()->bounded(2U) == 0); 0083 image[0] = nullptr; 0084 image[1] = nullptr; 0085 } 0086 0087 int deskX; 0088 int deskY; 0089 int deskWidth; 0090 int deskHeight; 0091 0092 QOpenGLTexture* endTexture; 0093 KBImageLoader* imageLoadThread; 0094 QTimer* mouseMoveTimer; 0095 QTimer* timer; 0096 bool haveImages; 0097 0098 KBImage* image[2]; 0099 KBEffect* effect; 0100 int numKBEffectRepeated; 0101 bool zoomIn; 0102 bool initialized; 0103 float step; 0104 float stepSameSpeed; 0105 0106 bool endOfShow; 0107 bool showingEnd; 0108 0109 int delay; 0110 bool disableFadeInOut; 0111 bool disableCrossFade; 0112 bool enableSameSpeed; 0113 unsigned forceFrameRate; 0114 0115 PresentationContainer* sharedData; 0116 0117 PresentationAudioWidget* playbackWidget; 0118 }; 0119 0120 } // namespace DigikamGenericPresentationPlugin 0121 0122 #endif // DIGIKAM_PRESENTATION_KB_PRIVATE_H