12#include "libmythbase/mythversion.h"
35 qRegisterMetaType<V2VideoMetadataInfo*>(
"V2VideoMetadataInfo");
36 qRegisterMetaType<V2VideoMetadataInfoList*>(
"V2VideoMetadataInfoList");
37 qRegisterMetaType<V2VideoLookupList*>(
"V2VideoLookupList");
38 qRegisterMetaType<V2BlurayInfo*>(
"V2BlurayInfo");
39 qRegisterMetaType<V2VideoStreamInfoList*>(
"V2VideoStreamInfoList");
40 qRegisterMetaType<V2VideoStreamInfo*>(
"V2VideoStreamInfo");
41 qRegisterMetaType<V2ArtworkInfoList*>(
"V2ArtworkInfoList");
42 qRegisterMetaType<V2ArtworkInfo*>(
"V2ArtworkInfo");
43 qRegisterMetaType<V2CastMemberList*>(
"V2CastMemberList");
44 qRegisterMetaType<V2CastMember*>(
"V2CastMember");
45 qRegisterMetaType<V2GenreList*>(
"V2GenreList");
46 qRegisterMetaType<V2Genre*>(
"V2Genre");
47 qRegisterMetaType<V2VideoLookupList*>(
"V2VideoLookupList");
48 qRegisterMetaType<V2VideoLookup*>(
"V2VideoLookup");
49 qRegisterMetaType<V2ArtworkItem*>(
"V2ArtworkItem");
50 qRegisterMetaType<V2CutList*>(
"V2CutList");
51 qRegisterMetaType<V2Cutting*>(
"V2Cutting");
52 qRegisterMetaType<V2VideoCategory*>(
"V2VideoCategory");
53 qRegisterMetaType<V2VideoCategoryList*>(
"V2VideoCategoryList");
67 throw( QString(
"No metadata found for selected ID!." ));
73 return pVideoMetadataInfo;
81 mlm->setList(videolist);
85 throw( QString(
"No metadata found for selected filename!." ));
91 return pVideoMetadataInfo;
103 query.
prepare(
"SELECT filename "
104 "FROM videometadata "
105 "WHERE intid = :ID ");
117 fileName = query.
value(0).toString();
120 LOG(VB_GENERAL, LOG_ERR, QString(
"V2Video/GetSavedBookmark Video id %1 Not found.").arg(Id));
150 query.
prepare(
"SELECT filename "
151 "FROM videometadata "
152 "WHERE intid = :ID ");
164 fileName = query.
value(0).toString();
167 LOG(VB_GENERAL, LOG_ERR, QString(
"V2Video/GetLastPlayPos Video id %1 Not found.").arg(Id));
210 const QString &TitleRegEx,
215 bool CollapseSubDirs )
217 QString fields =
"title,director,studio,plot,rating,year,releasedate,"
218 "userrating,length,playcount,filename,hash,showlevel,"
219 "coverfile,inetref,collectionref,homepage,childid,browse,watched,"
220 "playcommand,category,intid,trailer,screenshot,banner,fanart,"
221 "subtitle,tagline,season,episode,host,insertdate,processed,contenttype";
223 QStringList sortFields = fields.split(
',');
229 QStringList bindValues;
231 if (!Folder.isEmpty())
233 if (Folder.endsWith(
'/'))
236 folder = Folder +
"/";
237 sql.append(
" WHERE filename LIKE :BIND0 ");
238 bindValues.append(folder +
"%");
240 if (!TitleRegEx.isEmpty())
242 if (bindValues.empty())
244 sql.append(
" WHERE ");
250 sql.append(
" title REGEXP :BIND" + QString::number(bindValues.size()) +
" ");
251 bindValues.append(TitleRegEx);
255 if (bindValues.empty())
257 sql.append(
" WHERE ");
263 sql.append(
" category = :BIND" + QString::number(bindValues.size()) +
" ");
264 bindValues.append( QString::number(Category) );
266 sql.append(
" ORDER BY ");
267 QString defSeq =
" ASC";
271 QStringList sortList = Sort.toLower().split(
',',Qt::SkipEmptyParts);
273 for (
const auto & item : std::as_const(sortList))
275 QStringList partList = item.split(
' ',Qt::SkipEmptyParts);
276 if (partList.empty())
278 QString sort = partList[0];
281 else if (sort ==
"released")
282 sort =
"releasedate";
283 if (sortFields.contains(sort))
290 QString prefixes = sh->getPrefixes();
291 sort =
"REGEXP_REPLACE(title,'" + prefixes +
"','')";
293 else if (sort ==
"subtitle")
296 QString prefixes = sh->getPrefixes();
297 sort =
"REGEXP_REPLACE(subtitle,'" + prefixes +
"','')";
300 if (partList.length() > 1 && partList[1].compare(
"DESC",Qt::CaseInsensitive) == 0)
302 else if (partList.length() > 1 && partList[1].compare(
"ASC",Qt::CaseInsensitive) == 0)
316 std::vector<VideoMetadataListManager::VideoMetadataPtr> videos(videolist.begin(), videolist.end());
323 QMap<QString, QString> map;
324 int folderlen = folder.length();
326 nStartIndex = (nStartIndex > 0) ? std::min( nStartIndex, (
int)videos.size() ) : 0;
327 int selectedCount = 0;
334 for(
const auto& metadata : videos )
338 QString fnPart = metadata->GetFilename().mid(folderlen);
339 int slashPos = fnPart.indexOf(
'/',1);
342 dir = fnPart.mid(0, slashPos);
343 QString key = dir.toLower();
345 key = sh->doTitle(key);
346 if (!map.contains(key))
347 map.insert(key, dir);
352 auto addMetadata = [&](
const auto it)
354 if (totalCount >= nStartIndex && (nCount == 0 || selectedCount < nCount)) {
356 pVideoMetadataInfos->AddNewVideoMetadataInfo();
357 pVideoMetadataInfo->setContentType(
"DIRECTORY");
358 pVideoMetadataInfo->setFileName(folder + it.value());
359 pVideoMetadataInfo->setTitle(it.value());
368 for (
auto it = map.cend(); it != map.cbegin(); )
377 for (
auto it = map.cbegin(); it != map.cend(); it++) {
383 for(
const auto& metadata : videos )
390 QString fnPart = metadata->GetFilename().mid(folderlen);
391 int slashPos = fnPart.indexOf(
'/',1);
396 if (totalCount >= nStartIndex && (nCount == 0 || selectedCount < nCount)) {
409 totalPages = (int)ceil((
float)totalCount / nCount);
415 curPage = (int)ceil((
float)nStartIndex / nCount) + 1;
418 pVideoMetadataInfos->setStartIndex ( nStartIndex );
419 pVideoMetadataInfos->setCount ( selectedCount );
420 pVideoMetadataInfos->setCurrentPage ( curPage );
421 pVideoMetadataInfos->setTotalPages ( totalPages );
422 pVideoMetadataInfos->setTotalAvailable( totalCount );
424 pVideoMetadataInfos->setVersion ( MYTH_BINARY_VERSION );
425 pVideoMetadataInfos->setProtoVer ( MYTH_PROTO_VERSION );
427 return pVideoMetadataInfos;
432 const QString &Subtitle,
433 const QString &Inetref,
447 list = factory->SynchronousLookup(Title, Subtitle,
448 Inetref, Season, Episode,
453 return pVideoLookups;
457 for(
const auto & lookup : std::as_const(list))
459 V2VideoLookup *pVideoLookup = pVideoLookups->AddNewVideoLookup();
463 pVideoLookup->setTitle(lookup->GetTitle());
464 pVideoLookup->setSubTitle(lookup->GetSubtitle());
465 pVideoLookup->setSeason(lookup->GetSeason());
466 pVideoLookup->setEpisode(lookup->GetEpisode());
467 pVideoLookup->setYear(lookup->GetYear());
468 pVideoLookup->setTagline(lookup->GetTagline());
469 pVideoLookup->setDescription(lookup->GetDescription());
470 pVideoLookup->setCertification(lookup->GetCertification());
471 pVideoLookup->setInetref(lookup->GetInetref());
472 pVideoLookup->setCollectionref(lookup->GetCollectionref());
473 pVideoLookup->setHomePage(lookup->GetHomepage());
474#if QT_VERSION < QT_VERSION_CHECK(6,5,0)
475 pVideoLookup->setReleaseDate(
476 QDateTime(lookup->GetReleaseDate(),
477 QTime(0,0),Qt::LocalTime).toUTC());
479 pVideoLookup->setReleaseDate(
480 QDateTime(lookup->GetReleaseDate(),
482 QTimeZone(QTimeZone::LocalTime)).toUTC());
484 pVideoLookup->setUserRating(lookup->GetUserRating());
485 pVideoLookup->setLength(lookup->GetRuntime().count());
486 pVideoLookup->setLanguage(lookup->GetLanguage());
487 pVideoLookup->setCountries(lookup->GetCountries());
488 pVideoLookup->setPopularity(lookup->GetPopularity());
489 pVideoLookup->setBudget(lookup->GetBudget());
490 pVideoLookup->setRevenue(lookup->GetRevenue());
491 pVideoLookup->setIMDB(lookup->GetIMDB());
492 pVideoLookup->setTMSRef(lookup->GetTMSref());
495 ArtworkList::iterator c;
496 for (c = coverartlist.begin(); c != coverartlist.end(); ++c)
499 art->setType(
"coverart");
500 art->setUrl((*c).url);
501 art->setThumbnail((*c).thumbnail);
502 art->setWidth((*c).width);
503 art->setHeight((*c).height);
506 ArtworkList::iterator f;
507 for (f = fanartlist.begin(); f != fanartlist.end(); ++f)
510 art->setType(
"fanart");
511 art->setUrl((*f).url);
512 art->setThumbnail((*f).thumbnail);
513 art->setWidth((*f).width);
514 art->setHeight((*f).height);
517 ArtworkList::iterator b;
518 for (b = bannerlist.begin(); b != bannerlist.end(); ++b)
521 art->setType(
"banner");
522 art->setUrl((*b).url);
523 art->setThumbnail((*b).thumbnail);
524 art->setWidth((*b).width);
525 art->setHeight((*b).height);
528 ArtworkList::iterator s;
529 for (s = screenshotlist.begin(); s != screenshotlist.end(); ++s)
532 art->setType(
"screenshot");
533 art->setUrl((*s).url);
534 art->setThumbnail((*s).thumbnail);
535 art->setWidth((*s).width);
536 art->setHeight((*s).height);
541 pVideoLookups->setCount ( list.count() );
543 pVideoLookups->setVersion ( MYTH_BINARY_VERSION );
544 pVideoLookups->setProtoVer ( MYTH_PROTO_VERSION );
548 return pVideoLookups;
554 bool bResult =
false;
559 mlm->setList(videolist);
563 bResult = metadata->DeleteFromDatabase();
569 const QString &sHostName )
571 if ( sHostName.isEmpty() )
572 throw( QString(
"Host not provided! Local storage is deprecated and "
573 "is not supported by the API." ));
575 if ( sFileName.isEmpty() ||
576 (sFileName.contains(
"/../")) ||
577 (sFileName.startsWith(
"../")) )
579 throw( QString(
"Filename not provided, or fails sanity checks!" ));
584 QString fullname = sgroup.
FindFile(sFileName);
587 throw( QString(
"Provided filename does not exist!" ));
593 LOG(VB_GENERAL, LOG_ERR,
"Video Hash Failed. Unless this is a DVD or "
594 "Blu-ray, something has probably gone wrong.");
604 QString(), QString(), QString(), QString(),
630 mlm->setList(videolist);
636 metadata->SetWatched(bWatched);
637 metadata->UpdateDatabase();
643 const QString &sTitle,
644 const QString &sSubTitle,
645 const QString &sTagLine,
646 const QString &sDirector,
647 const QString &sStudio,
648 const QString &sPlot,
649 const QString &sRating,
650 const QString &sInetref,
652 const QString &sHomePage,
661 const QString &sFileName,
662 const QString &sHash,
663 const QString &sCoverFile,
668 const QString &sPlayCommand,
670 const QString &sTrailer,
671 const QString &sHost,
672 const QString &sScreenshot,
673 const QString &sBanner,
674 const QString &sFanart,
676 const QString &sContentType,
677 const QString &sGenres,
678 const QString &sCast,
679 const QString &sCountries)
681 bool update_required =
false;
685 mlm->setList(videolist);
690 LOG(VB_GENERAL, LOG_ERR, QString(
"UpdateVideoMetadata: Id=%1 not found")
697 metadata->SetTitle(sTitle);
698 update_required =
true;
703 metadata->SetSubtitle(sSubTitle);
704 update_required =
true;
709 metadata->SetTagline(sTagLine);
710 update_required =
true;
715 metadata->SetDirector(sDirector);
716 update_required =
true;
721 metadata->SetStudio(sStudio);
722 update_required =
true;
727 metadata->SetPlot(sPlot);
728 update_required =
true;
733 metadata->SetUserRating(fUserRating);
734 update_required =
true;
739 metadata->SetInetRef(sInetref);
740 update_required =
true;
745 metadata->SetCollectionRef(nCollectionRef);
746 update_required =
true;
751 metadata->SetHomepage(sHomePage);
752 update_required =
true;
757 metadata->SetYear(nYear);
758 update_required =
true;
763 metadata->SetReleaseDate(sReleasedate);
764 update_required =
true;
769 metadata->SetRating(sRating);
770 update_required =
true;
775 metadata->SetLength(std::chrono::minutes(nLength));
776 update_required =
true;
781 metadata->SetPlayCount(nPlayCount);
782 update_required =
true;
787 metadata->SetSeason(nSeason);
788 update_required =
true;
793 metadata->SetEpisode(nEpisode);
794 update_required =
true;
800 update_required =
true;
805 metadata->SetFilename(sFileName);
806 update_required =
true;
811 metadata->SetHash(sHash);
812 update_required =
true;
817 metadata->SetCoverFile(sCoverFile);
818 update_required =
true;
823 metadata->SetChildID(nChildID);
824 update_required =
true;
829 metadata->SetBrowse(bBrowse);
830 update_required =
true;
835 metadata->SetWatched(bWatched);
836 update_required =
true;
841 metadata->SetProcessed(bProcessed);
842 update_required =
true;
847 metadata->SetPlayCommand(sPlayCommand);
848 update_required =
true;
853 metadata->SetCategoryID(nCategory);
854 update_required =
true;
859 metadata->SetTrailer(sTrailer);
860 update_required =
true;
865 metadata->SetHost(sHost);
866 update_required =
true;
871 metadata->SetScreenshot(sScreenshot);
872 update_required =
true;
877 metadata->SetBanner(sBanner);
878 update_required =
true;
883 metadata->SetFanart(sFanart);
884 update_required =
true;
889 metadata->SetInsertdate(sInsertDate);
890 update_required =
true;
897 if (sContentType ==
"MOVIE")
900 if (sContentType ==
"TELEVISION")
903 if (sContentType ==
"ADULT")
906 if (sContentType ==
"MUSICVIDEO")
909 if (sContentType ==
"HOMEVIDEO")
914 metadata->SetContentType(contentType);
915 update_required =
true;
919 LOG(VB_GENERAL, LOG_ERR, QString(
"UpdateVideoMetadata: Ignoring unknown ContentType: %1").arg(sContentType));
926 QStringList genresList = sGenres.split(
',', Qt::SkipEmptyParts);
927 std::ranges::transform(std::as_const(genresList), std::back_inserter(genres),
928 [](
const QString& name)
929 {
return VideoMetadata::genre_list::value_type(-1, name.simplified());} );
931 metadata->SetGenres(genres);
932 update_required =
true;
938 QStringList castList = sCast.split(
',', Qt::SkipEmptyParts);
939 std::ranges::transform(std::as_const(castList), std::back_inserter(cast),
940 [](
const QString& name)
941 {
return VideoMetadata::cast_list::value_type(-1, name.simplified());} );
943 metadata->SetCast(cast);
944 update_required =
true;
950 QStringList countryList = sCountries.split(
',', Qt::SkipEmptyParts);
951 std::ranges::transform(std::as_const(countryList), std::back_inserter(countries),
952 [](
const QString& name)
953 {
return VideoMetadata::country_list::value_type(-1, name.simplified());} );
955 metadata->SetCountries(countries);
956 update_required =
true;
960 metadata->UpdateDatabase();
973 query.
prepare(
"SELECT filename "
974 "FROM videometadata "
975 "WHERE intid = :ID ");
987 fileName = query.
value(0).toString();
990 LOG(VB_GENERAL, LOG_ERR, QString(
"Video/SetSavedBookmark Video id %1 Not found.").arg(Id));
1020 query.
prepare(
"SELECT filename "
1021 "FROM videometadata "
1022 "WHERE intid = :ID ");
1034 fileName = query.
value(0).toString();
1037 LOG(VB_GENERAL, LOG_ERR, QString(
"Video/SetLastPlayPos Video id %1 Not found.").arg(Id));
1062 QString path = sPath;
1064 if (sPath.isEmpty())
1067 LOG(VB_GENERAL, LOG_NOTICE,
1068 QString(
"Parsing Blu-ray at path: %1 ").arg(path));
1073 throw( QString(
"Unable to open Blu-ray Metadata Parser!" ));
1075 if ( !bdmeta->OpenDisc() )
1076 throw( QString(
"Unable to open Blu-ray Disc/Path!" ));
1078 if ( !bdmeta->ParseDisc() )
1079 throw( QString(
"Unable to parse metadata from Blu-ray Disc/Path!" ));
1083 pBlurayInfo->setPath(path);
1084 pBlurayInfo->setTitle(bdmeta->GetTitle());
1085 pBlurayInfo->setAltTitle(bdmeta->GetAlternateTitle());
1086 pBlurayInfo->setDiscLang(bdmeta->GetDiscLanguage());
1087 pBlurayInfo->setDiscNum(bdmeta->GetCurrentDiscNumber());
1088 pBlurayInfo->setTotalDiscNum(bdmeta->GetTotalDiscNumber());
1089 pBlurayInfo->setTitleCount(bdmeta->GetTitleCount());
1090 pBlurayInfo->setThumbCount(bdmeta->GetThumbnailCount());
1091 pBlurayInfo->setTopMenuSupported(bdmeta->GetTopMenuSupported());
1092 pBlurayInfo->setFirstPlaySupported(bdmeta->GetFirstPlaySupported());
1093 pBlurayInfo->setNumHDMVTitles(bdmeta->GetNumHDMVTitles());
1094 pBlurayInfo->setNumBDJTitles(bdmeta->GetNumBDJTitles());
1095 pBlurayInfo->setNumUnsupportedTitles(bdmeta->GetNumUnsupportedTitles());
1096 pBlurayInfo->setAACSDetected(bdmeta->GetAACSDetected());
1097 pBlurayInfo->setLibAACSDetected(bdmeta->GetLibAACSDetected());
1098 pBlurayInfo->setAACSHandled(bdmeta->GetAACSHandled());
1099 pBlurayInfo->setBDPlusDetected(bdmeta->GetBDPlusDetected());
1100 pBlurayInfo->setLibBDPlusDetected(bdmeta->GetLibBDPlusDetected());
1101 pBlurayInfo->setBDPlusHandled(bdmeta->GetBDPlusHandled());
1103 QStringList thumbs = bdmeta->GetThumbnails();
1104 if (!thumbs.empty())
1105 pBlurayInfo->setThumbPath(thumbs.at(0));
1123 (
const QString &storageGroup,
1124 const QString &FileName )
1130 QString sFullFileName = storage.
FindFile( FileName );
1139 pVideoStreamInfos->setVersion ( MYTH_BINARY_VERSION );
1140 pVideoStreamInfos->setProtoVer ( MYTH_PROTO_VERSION );
1141 pVideoStreamInfos->setErrorCode ( infos.
m_errorCode );
1142 pVideoStreamInfos->setErrorMsg ( infos.
m_errorMsg );
1146 V2VideoStreamInfo *pVideoStreamInfo = pVideoStreamInfos->AddNewVideoStreamInfo();
1147 pVideoStreamInfo->setCodecType ( QString(QChar(
info.m_codecType)) );
1148 pVideoStreamInfo->setCodecName (
info.m_codecName );
1149 pVideoStreamInfo->setWidth (
info.m_width );
1150 pVideoStreamInfo->setHeight (
info.m_height );
1151 pVideoStreamInfo->setAspectRatio (
info.m_SampleAspectRatio );
1152 pVideoStreamInfo->setFieldOrder (
info.m_fieldOrder );
1153 pVideoStreamInfo->setFrameRate (
info.m_frameRate );
1154 pVideoStreamInfo->setAvgFrameRate (
info.m_avgFrameRate );
1155 pVideoStreamInfo->setChannels (
info.m_channels );
1156 pVideoStreamInfo->setDuration (
info.m_duration );
1159 return pVideoStreamInfos;
1168 const QString &offsettype,
1173 query.
prepare(
"SELECT filename "
1174 "FROM videometadata "
1175 "WHERE intid = :ID ");
1181 throw QString(
"Database Error.");
1187 fileName = query.
value(0).toString();
1190 LOG(VB_GENERAL, LOG_ERR, QString(
"V2Video/GetVideoCommBreak Video id %1 Not found.").arg(Id));
1191 throw QString(
"Video Not Found.");
1212 if (offsettype.toLower() ==
"position")
1214 else if (offsettype.toLower() ==
"duration")
1230 const QString &offsettype,
1235 query.
prepare(
"SELECT filename "
1236 "FROM videometadata "
1237 "WHERE intid = :ID ");
1243 throw QString(
"Database Error.");
1249 fileName = query.
value(0).toString();
1252 LOG(VB_GENERAL, LOG_ERR, QString(
"V2Video/GetVideoCommBreak Video id %1 Not found.").arg(Id));
1253 throw QString(
"Video Not Found.");
1274 if (offsettype.toLower() ==
"position")
1276 else if (offsettype.toLower() ==
"duration")
1291 query.
prepare(
"SELECT intid,category "
1292 "FROM videocategory ");
1297 throw QString(
"Database Error.");
1300 while (query.
next())
1302 auto *
cat = pCatList->AddNewCategory();
1303 cat->setId(query.
value(0).toInt());
1304 cat->setName(query.
value(1).toString());
QSqlQuery wrapper that fetches a DB connection from the connection pool.
bool prepare(const QString &query)
QSqlQuery::prepare() is not thread safe in Qt <= 3.3.2.
QVariant value(int i) const
bool exec(void)
Wrap QSqlQuery::exec() so we can display SQL.
void bindValue(const QString &placeholder, const QVariant &val)
Add a single binding.
bool next(void)
Wrap QSqlQuery::next() so we can display the query results.
static MSqlQueryInfo InitCon(ConnectionReuse _reuse=kNormalConnection)
Only use this in combination with MSqlQuery constructor.
QString GetSetting(const QString &key, const QString &defaultval="")
static void DBError(const QString &where, const MSqlQuery &query)
bool HAS_PARAMv2(const QString &p)
QVector< MythStreamInfo > m_streamInfoList
Holds information on recordings and videos.
void SaveLastPlayPos(uint64_t frame)
TODO Move to RecordingInfo.
uint64_t QueryLastPlayPos(void) const
Gets any lastplaypos position in database, unless the ignore lastplaypos flag is set.
uint64_t QueryBookmark(void) const
Gets any bookmark position in database, unless the ignore bookmark flag is set.
void SaveBookmark(uint64_t frame)
Clears any existing bookmark in DB and if frame is greater than 0 sets a new bookmark.
QString FindFile(const QString &filename)
V2ArtworkItem * AddNewArtwork()
bool UpdateVideoMetadata(int Id, const QString &Title, const QString &SubTitle, const QString &TagLine, const QString &Director, const QString &Studio, const QString &Plot, const QString &Rating, const QString &Inetref, int CollectionRef, const QString &HomePage, int Year, QDate ReleaseDate, float UserRating, int Length, int PlayCount, int Season, int Episode, int ShowLevel, const QString &FileName, const QString &Hash, const QString &CoverFile, int ChildID, bool Browse, bool Watched, bool Processed, const QString &PlayCommand, int Category, const QString &Trailer, const QString &Host, const QString &Screenshot, const QString &Banner, const QString &Fanart, QDate InsertDate, const QString &ContentType, const QString &Genres, const QString &Cast, const QString &Countries)
static V2CutList * GetVideoCutList(int Id, const QString &OffsetType, bool IncludeFps)
static bool AddVideo(const QString &FileName, const QString &HostName)
static V2VideoMetadataInfo * GetVideoByFileName(const QString &FileName)
static bool SetSavedBookmark(int Id, long Offset)
static void RegisterCustomTypes()
static bool UpdateVideoWatchedStatus(int Id, bool Watched)
static V2CutList * GetVideoCommBreak(int Id, const QString &OffsetType, bool IncludeFps)
static bool RemoveVideoFromDB(int Id)
static bool SetLastPlayPos(int Id, long Offset)
static long GetLastPlayPos(int Id)
static long GetSavedBookmark(int Id)
static V2VideoLookupList * LookupVideo(const QString &Title, const QString &Subtitle, const QString &Inetref, int Season, int Episode, const QString &GrabberType, bool AllowGeneric)
static V2BlurayInfo * GetBluray(const QString &Path)
V2VideoMetadataInfoList * GetVideoList(const QString &Folder, const QString &Sort, const QString &TitleRegEx, int Category, bool Descending, int StartIndex, int Count, bool CollapseSubDirs)
static V2VideoStreamInfoList * GetStreamInfo(const QString &StorageGroup, const QString &FileName)
static V2VideoMetadataInfo * GetVideo(int Id)
static V2VideoCategoryList * GetCategoryList()
const QString VIDEO_INETREF_DEFAULT
const QString VIDEO_PLOT_DEFAULT
const QString VIDEO_TRAILER_DEFAULT
const QString VIDEO_BANNER_DEFAULT
const QString VIDEO_SCREENSHOT_DEFAULT
const QString VIDEO_FANART_DEFAULT
const QString VIDEO_RATING_DEFAULT
const QString VIDEO_DIRECTOR_DEFAULT
const QString VIDEO_COVERFILE_DEFAULT
MythCoreContext * gCoreContext
This global variable contains the MythCoreContext instance for the app.
#define LOG(_MASK_, _LEVEL_, _QSTRING_)
QString FileHash(const QString &filename)
std::shared_ptr< MythSortHelper > getMythSortHelper(void)
Get a pointer to the MythSortHelper singleton.
QDateTime fromString(const QString &dtstr)
Converts kFilename && kISODate formats to QDateTime.
QDateTime current(bool stripped)
Returns current Date and Time in UTC.
void V2FillCommBreak(V2CutList *pCutList, ProgramInfo *rInfo, int marktype, bool includeFps)
void V2FillVideoMetadataInfo(V2VideoMetadataInfo *pVideoMetadataInfo, const VideoMetadataListManager::VideoMetadataPtr &pMetadata, bool bDetails)
void V2FillCutList(V2CutList *pCutList, ProgramInfo *rInfo, int marktype, bool includeFps)
Q_GLOBAL_STATIC_WITH_ARGS(MythHTTPMetaService, s_service,(VIDEO_HANDLE, V2Video::staticMetaObject, &V2Video::RegisterCustomTypes)) void V2Video