Skip to content

Commit

Permalink
Create the SkMultimedia library
Browse files Browse the repository at this point in the history
  • Loading branch information
3unjee committed May 30, 2022
1 parent fabe8be commit 7af914f
Show file tree
Hide file tree
Showing 13 changed files with 258 additions and 8 deletions.
4 changes: 4 additions & 0 deletions Sky.pro
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ isEmpty(TOOLS) {
src/SkMedia \
src/SkBarcode \

greaterThan(QT_MAJOR_VERSION, 4) {
SUBDIRS += src/SkMultimedia
}

# NOTE Qt5 Windows: The WebView module is only available for MSVC but currently unsupported.
# contains(QT_MAJOR_VERSION, 4) {
# SUBDIRS += src/SkWeb
Expand Down
4 changes: 3 additions & 1 deletion dist/changes/1.9.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@

## Global

- Create SkBarcode library.
- Create the SkBarcode library.

- Create the SkMultimedia library.

- Create Sk.pri.

Expand Down
1 change: 1 addition & 0 deletions include/SkMultimedia/WFilterBarcode
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#include "../../src/SkMultimedia/src/media/WFilterBarcode.h"
1 change: 1 addition & 0 deletions include/SkMultimedia/WFilterBarcode.h
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#include "../../src/SkMultimedia/src/media/WFilterBarcode.h"
1 change: 1 addition & 0 deletions include/SkMultimedia/private/WFilterBarcode_p
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#include "../../../src/SkMultimedia/src/media/WFilterBarcode_p.h"
1 change: 1 addition & 0 deletions include/SkMultimedia/private/WFilterBarcode_p.h
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#include "../../../src/SkMultimedia/src/media/WFilterBarcode_p.h"
3 changes: 2 additions & 1 deletion include/generate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ includeGenerator="../deploy/includeGenerator"
"$includeGenerator" ../../src/SkGui/src SkGui
"$includeGenerator" ../../src/SkGui/src/3rdparty/qtsingleapplication SkGui
"$includeGenerator" ../../src/SkMedia/src SkMedia
"$includeGenerator" ../../src/SkBarcode/src SkBarcode
"$includeGenerator" ../../src/SkMultimedia/src SkMultimedia
"$includeGenerator" ../../src/SkWeb/src SkWeb
"$includeGenerator" ../../src/SkTorrent/src SkTorrent
"$includeGenerator" ../../src/SkBarcode/src SkBarcode
"$includeGenerator" ../../src/SkBackend/src SkBackend
18 changes: 12 additions & 6 deletions src/SkCore/src/global/Sk.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,18 +48,24 @@ class WPrivate;
# define SK_MEDIA_EXPORT Q_DECL_IMPORT
#endif

#if defined(SK_WEB_LIBRARY)
# define SK_WEB_EXPORT Q_DECL_EXPORT
#else
# define SK_WEB_EXPORT Q_DECL_IMPORT
#endif

#if defined(SK_BARCODE_LIBRARY)
# define SK_BARCODE_EXPORT Q_DECL_EXPORT
#else
# define SK_BARCODE_EXPORT Q_DECL_IMPORT
#endif

#if defined(SK_MULTIMEDIA_LIBRARY)
# define SK_MULTIMEDIA_EXPORT Q_DECL_EXPORT
#else
# define SK_MULTIMEDIA_EXPORT Q_DECL_IMPORT
#endif

#if defined(SK_WEB_LIBRARY)
# define SK_WEB_EXPORT Q_DECL_EXPORT
#else
# define SK_WEB_EXPORT Q_DECL_IMPORT
#endif

#if defined(SK_TORRENT_LIBRARY)
# define SK_TORRENT_EXPORT Q_DECL_EXPORT
#else
Expand Down
79 changes: 79 additions & 0 deletions src/SkMultimedia/SkMultimedia.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
SK = $$_PRO_FILE_PWD_/../..

CONFIG(debug, debug|release) {
TARGET = SkMultimediaD
} else {
TARGET = SkMultimedia
}

DESTDIR = $$SK/lib

TEMPLATE = lib

QT += qml

win32:CONFIG += dll

# C++17
CONFIG += c++1z

DEFINES += SK_MULTIMEDIA_LIBRARY

unix:QMAKE_LFLAGS += "-Wl,-rpath,'\$$ORIGIN'"

include(../Sk.pri)
include(src/media/media.pri)

INCLUDEPATH += $$SK/include/SkCore \
$$SK/include/SkCore/private \
$$SK/include/SkGui \
$$SK/include/SkGui/private \
$$SK/include/SkBarcode \
$$SK/include/SkBarcode/private \
$$SK/include

android {
CONFIG(debug, debug|release) {

LIBS += -L$$SK/lib -lSkCoreD_$$ABI \
-L$$SK/lib -lSkGuiD_$$ABI \
-L$$SK/lib -lSkBarcodeD_$$ABI
} else {
LIBS += -L$$SK/lib -lSkCore_$$ABI \
-L$$SK/lib -lSkGui_$$ABI \
-L$$SK/lib -lSkBarcode_$$ABI
}
} else {
CONFIG(debug, debug|release) {

LIBS += -L$$SK/lib -lSkCoreD \
-L$$SK/lib -lSkGuiD \
-L$$SK/lib -lSkBarcodeD
} else {
LIBS += -L$$SK/lib -lSkCore \
-L$$SK/lib -lSkGui \
-L$$SK/lib -lSkBarcode
}
}

macx {
CONFIG(debug, debug|release) {
QMAKE_POST_LINK = install_name_tool -change libSkCoreD.dylib \
@loader_path/libSkCoreD.dylib $${DESTDIR}/lib$${TARGET}.dylib;

QMAKE_POST_LINK += install_name_tool -change libSkGuiD.dylib \
@loader_path/libSkGuiD.dylib $${DESTDIR}/lib$${TARGET}.dylib;

QMAKE_POST_LINK += install_name_tool -change libSkBarcodeD.dylib \
@loader_path/libSkBarcodeD.dylib $${DESTDIR}/lib$${TARGET}.dylib;
} else {
QMAKE_POST_LINK = install_name_tool -change libSkCore.dylib \
@loader_path/libSkCore.dylib $${DESTDIR}/lib$${TARGET}.dylib;

QMAKE_POST_LINK += install_name_tool -change libSkGui.dylib \
@loader_path/libSkGui.dylib $${DESTDIR}/lib$${TARGET}.dylib;

QMAKE_POST_LINK += install_name_tool -change libSkBarcode.dylib \
@loader_path/libSkBarcode.dylib $${DESTDIR}/lib$${TARGET}.dylib;
}
}
47 changes: 47 additions & 0 deletions src/SkMultimedia/src/media/WFilterBarcode.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
//=================================================================================================
/*
Copyright (C) 2015-2020 Sky kit authors. <http://omega.gg/Sky>
Author: Benjamin Arnaud. <http://bunjee.me> <[email protected]>
This file is part of SkMultimedia.
- GNU Lesser General Public License Usage:
This file may be used under the terms of the GNU Lesser General Public License version 3 as
published by the Free Software Foundation and appearing in the LICENSE.md file included in the
packaging of this file. Please review the following information to ensure the GNU Lesser
General Public License requirements will be met: https://www.gnu.org/licenses/lgpl.html.
- Private License Usage:
Sky kit licensees holding valid private licenses may use this file in accordance with the
private license agreement provided with the Software or, alternatively, in accordance with the
terms contained in written agreement between you and Sky kit authors. For further information
contact us at [email protected].
*/
//=================================================================================================

#include "WFilterBarcode.h"

#ifndef SK_NO_FILTERBARCODE

//-------------------------------------------------------------------------------------------------
// Private
//-------------------------------------------------------------------------------------------------

#include "WFilterBarcode_p.h"

WFilterBarcodePrivate::WFilterBarcodePrivate(WFilterBarcode * p) : WPrivate(p) {}

void WFilterBarcodePrivate::init() {}

//-------------------------------------------------------------------------------------------------
// Ctor / dtor
//-------------------------------------------------------------------------------------------------

/* explicit */ WFilterBarcode::WFilterBarcode(QObject * parent)
: QObject(parent), WPrivatable(new WFilterBarcodePrivate(this))
{
Q_D(WFilterBarcode); d->init();
}

#endif // SK_NO_FILTERBARCODE
48 changes: 48 additions & 0 deletions src/SkMultimedia/src/media/WFilterBarcode.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
//=================================================================================================
/*
Copyright (C) 2015-2020 Sky kit authors. <http://omega.gg/Sky>
Author: Benjamin Arnaud. <http://bunjee.me> <[email protected]>
This file is part of SkMultimedia.
- GNU Lesser General Public License Usage:
This file may be used under the terms of the GNU Lesser General Public License version 3 as
published by the Free Software Foundation and appearing in the LICENSE.md file included in the
packaging of this file. Please review the following information to ensure the GNU Lesser
General Public License requirements will be met: https://www.gnu.org/licenses/lgpl.html.
- Private License Usage:
Sky kit licensees holding valid private licenses may use this file in accordance with the
private license agreement provided with the Software or, alternatively, in accordance with the
terms contained in written agreement between you and Sky kit authors. For further information
contact us at [email protected].
*/
//=================================================================================================

#ifndef WFILTERBARCODE_H
#define WFILTERBARCODE_H

// Qt includes
#include <QObject>

// Sk includes
#include <Sk>

#ifndef SK_NO_FILTERBARCODE

class WFilterBarcodePrivate;

class SK_MULTIMEDIA_EXPORT WFilterBarcode : public QObject, public WPrivatable
{
Q_OBJECT

public:
explicit WFilterBarcode(QObject * parent = NULL);

private:
W_DECLARE_PRIVATE(WFilterBarcode)
};

#endif // SK_NO_FILTERBARCODE
#endif // WFILTERBARCODE_H
53 changes: 53 additions & 0 deletions src/SkMultimedia/src/media/WFilterBarcode_p.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
//=================================================================================================
/*
Copyright (C) 2015-2020 Sky kit authors. <http://omega.gg/Sky>
Author: Benjamin Arnaud. <http://bunjee.me> <[email protected]>
This file is part of SkMultimedia.
- GNU Lesser General Public License Usage:
This file may be used under the terms of the GNU Lesser General Public License version 3 as
published by the Free Software Foundation and appearing in the LICENSE.md file included in the
packaging of this file. Please review the following information to ensure the GNU Lesser
General Public License requirements will be met: https://www.gnu.org/licenses/lgpl.html.
- Private License Usage:
Sky kit licensees holding valid private licenses may use this file in accordance with the
private license agreement provided with the Software or, alternatively, in accordance with the
terms contained in written agreement between you and Sky kit authors. For further information
contact us at [email protected].
*/
//=================================================================================================

#ifndef WFILTERBARCODE_P_H
#define WFILTERBARCODE_P_H

/* W A R N I N G
-------------
This file is not part of the Sk API. It exists purely as an
implementation detail. This header file may change from version to
version without notice, or even be removed.
We mean it.
*/

// Private includes
#include <private/Sk_p>

#ifndef SK_NO_FILTERBARCODE

class SK_MULTIMEDIA_EXPORT WFilterBarcodePrivate : public WPrivate
{
public:
WFilterBarcodePrivate(WFilterBarcode * p);

void init();

protected:
W_DECLARE_PUBLIC(WFilterBarcode)
};

#endif // SK_NO_FILTERBARCODE
#endif // WFILTERBARCODE_P_H
6 changes: 6 additions & 0 deletions src/SkMultimedia/src/media/media.pri
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Media module

HEADERS += src/media/WFilterBarcode.h \
src/media/WFilterBarcode_p.h \

SOURCES += src/media/WFilterBarcode.cpp \

0 comments on commit 7af914f

Please sign in to comment.