libmatroska: remove all references to the old/outdated/previous tag system
git-svn-id: https://matroska.svn.sourceforge.net/svnroot/matroska/trunk/libmatroska@385 a6f86f6d-0131-4f8e-9e7b-e335508773d5
This commit is contained in:
parent
73aa75ee8a
commit
64b3fed7f6
@ -36,7 +36,6 @@ LIB matroska
|
||||
SOURCE src/KaxSeekHead.cpp
|
||||
SOURCE src/KaxSegment.cpp
|
||||
SOURCE src/KaxTag.cpp
|
||||
SOURCE src/KaxTagMulti.cpp
|
||||
SOURCE src/KaxTags.cpp
|
||||
SOURCE src/KaxTrackAudio.cpp
|
||||
SOURCE src/KaxTrackEntryData.cpp
|
||||
@ -63,7 +62,6 @@ LIB matroska
|
||||
HEADER matroska/KaxSeekHead.h
|
||||
HEADER matroska/KaxSegment.h
|
||||
HEADER matroska/KaxTag.h
|
||||
HEADER matroska/KaxTagMulti.h
|
||||
HEADER matroska/KaxTags.h
|
||||
HEADER matroska/KaxTrackAudio.h
|
||||
HEADER matroska/KaxTrackEntryData.h
|
||||
|
@ -56,18 +56,6 @@ DECLARE_MKX_MASTER(KaxTag)
|
||||
DECLARE_MKX_MASTER(KaxTagTargets)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagGeneral)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagGenres)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagAudioSpecific)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagImageSpecific)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagTargetTypeValue)
|
||||
};
|
||||
|
||||
@ -86,128 +74,9 @@ DECLARE_MKX_UINTEGER(KaxTagChapterUID)
|
||||
DECLARE_MKX_UINTEGER(KaxTagAttachmentUID)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagArchivalLocation)
|
||||
};
|
||||
|
||||
DECLARE_MKX_BINARY(KaxTagAudioEncryption)
|
||||
};
|
||||
|
||||
DECLARE_MKX_FLOAT(KaxTagAudioGain)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagAudioGenre)
|
||||
};
|
||||
|
||||
DECLARE_MKX_FLOAT(KaxTagAudioPeak)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagBibliography)
|
||||
};
|
||||
|
||||
DECLARE_MKX_FLOAT(KaxTagBPM)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagCaptureDPI)
|
||||
};
|
||||
|
||||
DECLARE_MKX_BINARY(KaxTagCaptureLightness)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagCapturePaletteSetting)
|
||||
};
|
||||
|
||||
DECLARE_MKX_BINARY(KaxTagCaptureSharpness)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagCropped)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagDiscTrack)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagEncoder)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagEncodeSettings)
|
||||
};
|
||||
|
||||
DECLARE_MKX_BINARY(KaxTagEqualisation)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagFile)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagInitialKey)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagKeywords)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagLanguage)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagLength)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMood)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagOfficialAudioFileURL)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagOfficialAudioSourceURL)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagOriginalDimensions)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagOriginalMediaType)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagPlayCounter)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagPlaylistDelay)
|
||||
};
|
||||
|
||||
DECLARE_MKX_SINTEGER(KaxTagPopularimeter)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagProduct)
|
||||
};
|
||||
|
||||
DECLARE_MKX_BINARY(KaxTagRating)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagRecordLocation)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagSetPart)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagSource)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagSourceForm)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagSubGenre)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagSubject)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagUnsynchronisedText)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagUserDefinedURL)
|
||||
};
|
||||
|
||||
DECLARE_MKX_BINARY(KaxTagVideoGenre)
|
||||
public:
|
||||
virtual bool ValidateSize() const {return IsFiniteSize() && (GetSize() >= 2);}
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagSimple)
|
||||
};
|
||||
|
||||
|
@ -1,304 +0,0 @@
|
||||
/****************************************************************************
|
||||
** libmatroska : parse Matroska files, see http://www.matroska.org/
|
||||
**
|
||||
** <file/class MATROSKA_DLL_API description>
|
||||
**
|
||||
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
|
||||
**
|
||||
** This file is part of libmatroska.
|
||||
**
|
||||
** This library is free software; you can redistribute it and/or
|
||||
** modify it under the terms of the GNU Lesser General Public
|
||||
** License as published by the Free Software Foundation; either
|
||||
** version 2.1 of the License, or (at your option) any later version.
|
||||
**
|
||||
** This library is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
** Lesser General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU Lesser General Public
|
||||
** License along with this library; if not, write to the Free Software
|
||||
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
**
|
||||
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
|
||||
** Contact license@matroska.org if any conditions of this licensing are
|
||||
** not clear to you.
|
||||
**
|
||||
**********************************************************************/
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id$
|
||||
\author Jory Stone <jcsston @ toughguy.net>
|
||||
\author Steve Lhomme <robux4 @ users.sf.net>
|
||||
*/
|
||||
#ifndef LIBMATROSKA_TAGMULTI_H
|
||||
#define LIBMATROSKA_TAGMULTI_H
|
||||
|
||||
#include "matroska/KaxTypes.h"
|
||||
#include "ebml/EbmlMaster.h"
|
||||
#include "ebml/EbmlDate.h"
|
||||
#include "ebml/EbmlFloat.h"
|
||||
#include "ebml/EbmlSInteger.h"
|
||||
#include "ebml/EbmlUInteger.h"
|
||||
#include "ebml/EbmlString.h"
|
||||
#include "ebml/EbmlUnicodeString.h"
|
||||
#include "ebml/EbmlBinary.h"
|
||||
#include "matroska/KaxDefines.h"
|
||||
|
||||
using namespace LIBEBML_NAMESPACE;
|
||||
|
||||
START_LIBMATROSKA_NAMESPACE
|
||||
|
||||
enum KaxTagMultiCommercialTypes {
|
||||
KaxTagMultiCommercialType_FilePurchase = 1, //Information on where to purchase this file. This is akin to the WPAY tag in ID3.
|
||||
KaxTagMultiCommercialType_ItemPurchase, //Information on where to purchase this album. This is akin to the WCOM tag in ID3.
|
||||
KaxTagMultiCommercialType_Owner //Information on the purchase that occurred for this file. This is akin to the OWNE tag in ID3.
|
||||
};
|
||||
enum KaxTagMultiDateTypes {
|
||||
KaxTagMultiDateType_EncodingDate = 1, //The time that the encoding of this item was completed. This is akin to the TDEN tag in ID3.
|
||||
KaxTagMultiDateType_RecordingDate, //The time that the recording began, and finished. This is akin to the TDRC tag in ID3.
|
||||
KaxTagMultiDateType_ReleaseDate, //The time that the item was originaly released. This is akin to the TDRL tag in ID3.
|
||||
KaxTagMultiDateType_OriginalReleaseDate, //The time that the item was originaly released if it is a remake. This is akin to the TDOR tag in ID3.
|
||||
KaxTagMultiDateType_TaggingDate, //The time that the tags were done for this item. This is akin to the TDTG tag in ID3.
|
||||
KaxTagMultiDateType_DigitizingDate //The time that the item was tranfered to a digital medium. This is akin to the IDIT tag in RIFF
|
||||
};
|
||||
enum KaxTagMultiEntitiesTypes {
|
||||
KaxTagMultiEntitiesType_LyricistTextWriter = 1, //The person that wrote the words/script for this item. This is akin to the TEXT tag in ID3.
|
||||
KaxTagMultiEntitiesType_Composer, //The name of the composer of this item. This is akin to the TCOM tag in ID3.
|
||||
KaxTagMultiEntitiesType_LeadPerformerSoloist, //This is akin to the TPE1 tag in ID3.
|
||||
KaxTagMultiEntitiesType_BandOrchestraAccompaniment, //This is akin to the TPE2 tag in ID3.
|
||||
KaxTagMultiEntitiesType_OriginalLyricistTextWriter, //This is akin to the TOLY tag in ID3.
|
||||
KaxTagMultiEntitiesType_OriginalArtistPerformer, //This is akin to the TOPE tag in ID3.
|
||||
KaxTagMultiEntitiesType_OriginalAlbumMovieShowTitle, //This is akin to the TOAL tag in ID3.
|
||||
KaxTagMultiEntitiesType_ConductorPerformerRefinement, //This is akin to the TPE3 tag in ID3.
|
||||
KaxTagMultiEntitiesType_InterpretedRemixedBy, //This is akin to the TPE4 tag in ID3.
|
||||
KaxTagMultiEntitiesType_Director, //This is akin to the IART tag in RIFF
|
||||
KaxTagMultiEntitiesType_ProducedBy, //This is akin to the IPRO tag in Extended RIFF
|
||||
KaxTagMultiEntitiesType_Cinematographer, //This is akin to the ICNM tag in Extended RIFF
|
||||
KaxTagMultiEntitiesType_ProductionDesigner, //This is akin to the IPDS tag in Extended RIFF
|
||||
KaxTagMultiEntitiesType_CostumeDesigner, //This is akin to the ICDS tag in Extended RIFF
|
||||
KaxTagMultiEntitiesType_ProductionStudio, //This is akin to the ISTD tag in Extended RIFF
|
||||
KaxTagMultiEntitiesType_DistributedBy, //This is akin to the IDST tag in Extended RIFF
|
||||
KaxTagMultiEntitiesType_CommissionedBy, //This is akin to the ICMS tag in RIFF
|
||||
KaxTagMultiEntitiesType_Engineer, //This is akin to the IENG tag in RIFF
|
||||
KaxTagMultiEntitiesType_EditedBy, //This is akin to the IEDT tag in Extended RIFF
|
||||
KaxTagMultiEntitiesType_EncodedBy, //This is akin to the TENC tag in ID3.
|
||||
KaxTagMultiEntitiesType_RippedBy, //This is akin to the IRIP tag in Extended RIFF
|
||||
KaxTagMultiEntitiesType_InvolvedPeopleList, //A very general tag for everyone else that wants to be listed. This is akin to the TMCL tag in ID3.
|
||||
KaxTagMultiEntitiesType_InternetRadioStationName, //This is akin to the TSRN tag in ID3.
|
||||
KaxTagMultiEntitiesType_Publisher //This is akin to the TPUB tag in ID3.
|
||||
};
|
||||
|
||||
enum KaxTagMultiIdentifierTypes {
|
||||
KaxTagMultiIdentifierType_ISRC = 1, //String, The International Standard Recording Code
|
||||
KaxTagMultiIdentifierType_CDIdentifier, //Binary, This is a binary dump of the TOC of the CDROM that this item was taken from. This holds the same information as the MCDI in ID3.
|
||||
KaxTagMultiIdentifierType_ISBN, //String, International Standard Book Number
|
||||
KaxTagMultiIdentifierType_Catalog, //String, sometimes the EAN/UPC, often some letters followed by some numbers
|
||||
KaxTagMultiIdentifierType_EAN, //String, EAN-13 bar code identifier
|
||||
KaxTagMultiIdentifierType_UPC, //String, UPC-A bar code identifier
|
||||
KaxTagMultiIdentifierType_LabelCode, //String, Typically printed as ________ (LC) xxxx) ~~~~~~~~ or _________ (LC) 0xxxx) ~~~~~~~~~ on CDs medias or covers, where xxxx is a 4-digit number.
|
||||
KaxTagMultiIdentifierType_LCCN, //String, Library of Congress Control Number
|
||||
KaxTagMultiIdentifierType_UniqueFileIdentifier, //Binary, This used for a dump of the UFID field in ID3. This field would only be used if the item was pulled from an MP3.
|
||||
CDROM_CD_TEXT_PACK_TOC_INFO2 //Binary
|
||||
};
|
||||
|
||||
enum KaxTagMultiLegalTypes {
|
||||
KaxTagMultiLegalType_Copyright = 1, //The copyright information as per the copyright holder. This is akin to the TCOP tag in ID3.
|
||||
KaxTagMultiLegalType_ProductionCopyright, //The copyright information as per the production copyright holder. This is akin to the TPRO tag in ID3.
|
||||
KaxTagMultiLegalType_TermsOfUse //The terms of use for this item. This is akin to the USER tag in ID3.
|
||||
};
|
||||
|
||||
enum KaxTagMultiTitleTypes {
|
||||
KaxTagMultiTitleType_TrackTitle = 1,
|
||||
//The title of this item. In the case of a track, the Name element should be identical to the Name element.
|
||||
//For example, for music you might label this "Canon in D", or for video's audio track you might use "English 5.1" This is akin to the TIT2 tag in ID3.
|
||||
KaxTagMultiTitleType_AlbumMovieShowTitle,
|
||||
//This is the name given to a grouping of tracks and/or chapters.
|
||||
//For example, all video, audio, and subtitle tracks for a movie would be grouped under this and be given the name of the movie.
|
||||
//All tracks for a particular CD would be grouped together under the title of the CD, or if all tracks for a CD were recorded as a single track, seperated by chapters, the same would apply.
|
||||
//You could use this to label episode 3 of The Simpsons. This is akin to the TALB tag in ID3.
|
||||
KaxTagMultiTitleType_SetTitle, //This would be used to label a set of ID 2. For example, season 13 of The Simpsons.
|
||||
KaxTagMultiTitleType_Series //This would be used to label a set of ID 3. For example, The Simpsons.
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagMultiComment)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiCommentName)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiCommentComments)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiCommentLanguage)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagMultiCommercial)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagCommercial)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagMultiCommercialType)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiCommercialAddress)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiCommercialURL)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiCommercialEmail)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagMultiPrice)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiPriceCurrency)
|
||||
};
|
||||
|
||||
DECLARE_MKX_FLOAT(KaxTagMultiPriceAmount)
|
||||
};
|
||||
|
||||
DECLARE_MKX_DATE(KaxTagMultiPricePriceDate)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagMultiDate)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagDate)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagMultiDateType)
|
||||
};
|
||||
|
||||
DECLARE_MKX_DATE(KaxTagMultiDateDateBegin)
|
||||
};
|
||||
|
||||
DECLARE_MKX_DATE(KaxTagMultiDateDateEnd)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagMultiEntity)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagEntity)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagMultiEntityType)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiEntityName)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiEntityAddress)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiEntityURL)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiEntityEmail)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagMultiIdentifier)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagIdentifier)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagMultiIdentifierType)
|
||||
};
|
||||
|
||||
DECLARE_MKX_BINARY(KaxTagMultiIdentifierBinary)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiIdentifierString)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagMultiLegal)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagLegal)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagMultiLegalType)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiLegalContent)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiLegalURL)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiLegalAddress)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagMultiTitle)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagTitle)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagMultiTitleType)
|
||||
};
|
||||
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiTitleName)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiTitleSubTitle)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiTitleEdition)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxTagMultiTitleAddress)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiTitleURL)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiTitleEmail)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagMultiTitleLanguage)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagMultiAttachment)
|
||||
};
|
||||
|
||||
DECLARE_MKX_MASTER(KaxTagAttachment)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagAttachmentID)
|
||||
};
|
||||
|
||||
#if 0
|
||||
DECLARE_MKX_FLOAT(KaxTagBPM)
|
||||
};
|
||||
|
||||
DECLARE_MKX_SINTEGER(KaxTagPopularimeter)
|
||||
};
|
||||
|
||||
DECLARE_MKX_BINARY(KaxTagRating)
|
||||
};
|
||||
|
||||
DECLARE_MKX_UINTEGER(KaxTagSetPart)
|
||||
};
|
||||
|
||||
DECLARE_MKX_STRING(KaxTagUserDefinedURL)
|
||||
};
|
||||
|
||||
DECLARE_MKX_BINARY(KaxTagVideoSecondaryGenre)
|
||||
public:
|
||||
virtual bool ValidateSize() const {return IsFiniteSize() && (Size >= 4);
|
||||
};
|
||||
|
||||
DECLARE_MKX_UNISTRING(KaxWritingApp)
|
||||
};
|
||||
#endif
|
||||
|
||||
END_LIBMATROSKA_NAMESPACE
|
||||
|
||||
#endif // LIBMATROSKA_TAGMULTI_H
|
277
src/KaxTag.cpp
277
src/KaxTag.cpp
@ -1,193 +1,84 @@
|
||||
/****************************************************************************
|
||||
** libmatroska : parse Matroska files, see http://www.matroska.org/
|
||||
**
|
||||
** <file/class description>
|
||||
**
|
||||
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
|
||||
**
|
||||
** This file is part of libmatroska.
|
||||
**
|
||||
** This library is free software; you can redistribute it and/or
|
||||
** modify it under the terms of the GNU Lesser General Public
|
||||
** License as published by the Free Software Foundation; either
|
||||
** version 2.1 of the License, or (at your option) any later version.
|
||||
**
|
||||
** This library is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
** Lesser General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU Lesser General Public
|
||||
** License along with this library; if not, write to the Free Software
|
||||
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
**
|
||||
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
|
||||
** Contact license@matroska.org if any conditions of this licensing are
|
||||
** not clear to you.
|
||||
**
|
||||
**********************************************************************/
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: KaxTag.cpp 1325 2009-03-30 07:56:54Z robux4 $
|
||||
\author Jory Stone <jcsston @ toughguy.net>
|
||||
\author Steve Lhomme <robux4 @ users.sf.net>
|
||||
*/
|
||||
#include "matroska/KaxTag.h"
|
||||
#include "matroska/KaxTagMulti.h"
|
||||
#include "matroska/KaxContexts.h"
|
||||
#include "matroska/KaxDefines.h"
|
||||
|
||||
using namespace LIBEBML_NAMESPACE;
|
||||
|
||||
// sub elements
|
||||
START_LIBMATROSKA_NAMESPACE
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTag)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagTargets)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagGeneral)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagGenres)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagAudioSpecific)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagImageSpecific)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiCommercial)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiDate)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiEntity)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiIdentifier)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiLegal)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiTitle)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiAttachment)
|
||||
//DEFINE_SEMANTIC_ITEM(false, false, KaxTagLength)
|
||||
//DEFINE_SEMANTIC_ITEM(false, false, KaxTagPlaylistDelay)
|
||||
//DEFINE_SEMANTIC_ITEM(false, false, KaxTagUnsynchronisedText)
|
||||
//DEFINE_SEMANTIC_ITEM(false, false, KaxTagUserDefinedURL)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiComment)
|
||||
DEFINE_SEMANTIC_ITEM(true, false, KaxTagSimple)
|
||||
DEFINE_END_SEMANTIC(KaxTag)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagTargets)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagTargetTypeValue)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagTargetType)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagTrackUID)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagEditionUID)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagChapterUID)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagAttachmentUID)
|
||||
DEFINE_END_SEMANTIC(KaxTagTargets)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagGeneral)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagArchivalLocation)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagFile)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagKeywords)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMood)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagRecordLocation)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagSource)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagSourceForm)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagProduct)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagOriginalMediaType)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagPlayCounter)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagPopularimeter)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagSubject)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagBibliography)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagLanguage)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagRating)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagEncoder)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagEncodeSettings)
|
||||
DEFINE_END_SEMANTIC(KaxTagGeneral)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagGenres)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagAudioGenre)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagVideoGenre)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagSubGenre)
|
||||
DEFINE_END_SEMANTIC(KaxTagGenres)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagAudioSpecific)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagAudioPeak)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagAudioEncryption)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagAudioGain)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagBPM)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagDiscTrack)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagSetPart)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagEqualisation)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagInitialKey)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagOfficialAudioFileURL)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagOfficialAudioSourceURL)
|
||||
DEFINE_END_SEMANTIC(KaxTagAudioSpecific)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagImageSpecific)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagCaptureDPI)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagCaptureLightness)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagCapturePaletteSetting)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagCaptureSharpness)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagCropped)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagOriginalDimensions)
|
||||
DEFINE_END_SEMANTIC(KaxTagImageSpecific)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagSimple)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagName)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagLangue)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagDefault)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagString)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagBinary)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagSimple)
|
||||
DEFINE_END_SEMANTIC(KaxTagSimple)
|
||||
|
||||
DEFINE_MKX_MASTER (KaxTag, 0x7373, 2, KaxTags, "Tag");
|
||||
DEFINE_MKX_MASTER (KaxTagTargets, 0x63C0, 2, KaxTag, "TagTargets");
|
||||
DEFINE_MKX_MASTER (KaxTagGeneral, 0x67C9, 2, KaxTag, "TagGeneral");
|
||||
DEFINE_MKX_MASTER (KaxTagGenres, 0x6583, 2, KaxTag, "TagGenres");
|
||||
DEFINE_MKX_MASTER (KaxTagAudioSpecific, 0x41C5, 2, KaxTag, "TagAudioSpecific");
|
||||
DEFINE_MKX_MASTER (KaxTagImageSpecific, 0x4990, 2, KaxTag, "TagImageSpecific");
|
||||
DEFINE_MKX_UNISTRING (KaxTagBibliography, 0x4488, 2, KaxTag, "Bibliography");
|
||||
DEFINE_MKX_UNISTRING (KaxTagEncoder, 0x4431, 2, KaxTag, "Encoder");
|
||||
DEFINE_MKX_UNISTRING (KaxTagEncodeSettings, 0x6526, 2, KaxTag, "EncodeSettings");
|
||||
DEFINE_MKX_STRING (KaxTagLanguage, 0x22B59F, 3, KaxTag, "Language");
|
||||
DEFINE_MKX_UINTEGER (KaxTagLength, 0x5243, 2, KaxTag, "Length");
|
||||
DEFINE_MKX_UINTEGER (KaxTagPlaylistDelay, 0x72CC, 2, KaxTag, "PlaylistDelay");
|
||||
DEFINE_MKX_BINARY (KaxTagRating, 0x52BC, 2, KaxTag, "Rating");
|
||||
DEFINE_MKX_UNISTRING (KaxTagSubject, 0x49C1, 2, KaxTag, "Subject");
|
||||
DEFINE_MKX_UNISTRING (KaxTagUnsynchronisedText, 0x874B, 2, KaxTag, "UnsynchronisedText");
|
||||
DEFINE_MKX_STRING (KaxTagUserDefinedURL, 0x434A, 2, KaxTag, "UserDefinedURL");
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagTargetTypeValue, 0x68CA, 2, KaxTagTargets, "TagTargetTypeValue", 50);
|
||||
DEFINE_MKX_STRING (KaxTagTargetType, 0x63CA, 2, KaxTagTargets, "TagTargetType");
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagTrackUID, 0x63C5, 2, KaxTagTargets, "TagTrackUID", 0);
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagEditionUID, 0x63C9, 2, KaxTagTargets, "TagEditionUID", 0);
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagChapterUID, 0x63C4, 2, KaxTagTargets, "TagChapterUID", 0);
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagAttachmentUID, 0x63C6, 2, KaxTagTargets, "TagAttachmentUID", 0);
|
||||
DEFINE_MKX_UNISTRING (KaxTagArchivalLocation, 0x45A4, 2, KaxTagGeneral, "ArchivalLocation");
|
||||
DEFINE_MKX_UNISTRING (KaxTagFile, 0x454E, 2, KaxTagGeneral, "File");
|
||||
DEFINE_MKX_UNISTRING (KaxTagKeywords, 0x458C, 2, KaxTagGeneral, "Keywords");
|
||||
DEFINE_MKX_UNISTRING (KaxTagMood, 0x45AE, 2, KaxTagGeneral, "Mood");
|
||||
DEFINE_MKX_STRING (KaxTagRecordLocation, 0x457E, 2, KaxTagGeneral, "RecordLocation");
|
||||
DEFINE_MKX_UNISTRING (KaxTagSource, 0x458A, 2, KaxTagGeneral, "Source");
|
||||
DEFINE_MKX_UNISTRING (KaxTagSourceForm, 0x45B5, 2, KaxTagGeneral, "SourceForm");
|
||||
DEFINE_MKX_UNISTRING (KaxTagProduct, 0x45E3, 2, KaxTagGeneral, "Product");
|
||||
DEFINE_MKX_UNISTRING (KaxTagOriginalMediaType, 0x45A7, 2, KaxTagGeneral, "OriginalMediaType");
|
||||
DEFINE_MKX_UINTEGER (KaxTagPlayCounter, 0x4566, 2, KaxTagTargets, "PlayCounter");
|
||||
DEFINE_MKX_SINTEGER (KaxTagPopularimeter, 0x4532, 2, KaxTagTargets, "Popularimeter");
|
||||
DEFINE_MKX_STRING (KaxTagAudioGenre, 0x65C2, 2, KaxTagGenres, "AudioGenre");
|
||||
DEFINE_MKX_BINARY (KaxTagVideoGenre, 0x65A1, 2, KaxTagGenres, "VideoGenre");
|
||||
DEFINE_MKX_STRING (KaxTagSubGenre, 0x65AC, 2, KaxTagGenres, "SubGenre");
|
||||
DEFINE_MKX_BINARY (KaxTagAudioEncryption, 0x41B4, 2, KaxTagAudioSpecific, "AudioEncryption");
|
||||
DEFINE_MKX_FLOAT (KaxTagAudioGain, 0x4199, 2, KaxTagAudioSpecific, "AudioGain");
|
||||
DEFINE_MKX_FLOAT (KaxTagAudioPeak, 0x4189, 2, KaxTagAudioSpecific, "AudioPeak");
|
||||
DEFINE_MKX_FLOAT (KaxTagBPM, 0x41A1, 2, KaxTagAudioSpecific, "BPM");
|
||||
DEFINE_MKX_UINTEGER (KaxTagDiscTrack, 0x41B6, 2, KaxTagAudioSpecific, "DiscTrack");
|
||||
DEFINE_MKX_UINTEGER (KaxTagSetPart, 0x416E, 2, KaxTagAudioSpecific, "SetPart");
|
||||
DEFINE_MKX_BINARY (KaxTagEqualisation, 0x41B1, 2, KaxTagAudioSpecific, "Equalisation");
|
||||
DEFINE_MKX_STRING (KaxTagInitialKey, 0x413A, 2, KaxTagAudioSpecific, "InitialKey");
|
||||
DEFINE_MKX_STRING (KaxTagOfficialAudioFileURL, 0x4133, 2, KaxTagAudioSpecific, "OfficialAudioFileURL");
|
||||
DEFINE_MKX_STRING (KaxTagOfficialAudioSourceURL, 0x413E, 2, KaxTagAudioSpecific, "AudioSourceURL");
|
||||
DEFINE_MKX_UINTEGER (KaxTagCaptureDPI, 0x49C7, 2, KaxTagImageSpecific, "CaptureDPI");
|
||||
DEFINE_MKX_BINARY (KaxTagCaptureLightness, 0x49E1, 2, KaxTagImageSpecific, "CaptureLightness");
|
||||
DEFINE_MKX_UINTEGER (KaxTagCapturePaletteSetting, 0x4934, 2, KaxTagImageSpecific, "CapturePaletteSetting");
|
||||
DEFINE_MKX_BINARY (KaxTagCaptureSharpness, 0x4922, 2, KaxTagImageSpecific, "CaptureSharpness");
|
||||
DEFINE_MKX_UNISTRING (KaxTagCropped, 0x4987, 2, KaxTagImageSpecific, "Cropped");
|
||||
DEFINE_MKX_STRING (KaxTagOriginalDimensions, 0x4933, 2, KaxTagImageSpecific, "OriginalDimensions");
|
||||
|
||||
DEFINE_MKX_MASTER (KaxTagSimple, 0x67C8, 2, KaxTag, "TagSimple");
|
||||
DEFINE_MKX_UNISTRING (KaxTagName, 0x45A3, 2, KaxTagSimple, "TagName");
|
||||
DEFINE_MKX_STRING_DEF (KaxTagLangue, 0x447A, 2, KaxTagSimple, "TagLanguage", "und");
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagDefault, 0x4484, 2, KaxTagSimple, "TagDefault", 1);
|
||||
DEFINE_MKX_UNISTRING (KaxTagString, 0x4487, 2, KaxTagSimple, "TagString");
|
||||
DEFINE_MKX_BINARY (KaxTagBinary, 0x4485, 2, KaxTagSimple, "TagBinary");
|
||||
|
||||
END_LIBMATROSKA_NAMESPACE
|
||||
/****************************************************************************
|
||||
** libmatroska : parse Matroska files, see http://www.matroska.org/
|
||||
**
|
||||
** <file/class description>
|
||||
**
|
||||
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
|
||||
**
|
||||
** This file is part of libmatroska.
|
||||
**
|
||||
** This library is free software; you can redistribute it and/or
|
||||
** modify it under the terms of the GNU Lesser General Public
|
||||
** License as published by the Free Software Foundation; either
|
||||
** version 2.1 of the License, or (at your option) any later version.
|
||||
**
|
||||
** This library is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
** Lesser General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU Lesser General Public
|
||||
** License along with this library; if not, write to the Free Software
|
||||
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
**
|
||||
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
|
||||
** Contact license@matroska.org if any conditions of this licensing are
|
||||
** not clear to you.
|
||||
**
|
||||
**********************************************************************/
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: KaxTag.cpp 1325 2009-03-30 07:56:54Z robux4 $
|
||||
\author Jory Stone <jcsston @ toughguy.net>
|
||||
\author Steve Lhomme <robux4 @ users.sf.net>
|
||||
*/
|
||||
#include "matroska/KaxTag.h"
|
||||
#include "matroska/KaxContexts.h"
|
||||
#include "matroska/KaxDefines.h"
|
||||
|
||||
using namespace LIBEBML_NAMESPACE;
|
||||
|
||||
// sub elements
|
||||
START_LIBMATROSKA_NAMESPACE
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTag)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagTargets)
|
||||
DEFINE_SEMANTIC_ITEM(true, false, KaxTagSimple)
|
||||
DEFINE_END_SEMANTIC(KaxTag)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagTargets)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagTargetTypeValue)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagTargetType)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagTrackUID)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagEditionUID)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagChapterUID)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagAttachmentUID)
|
||||
DEFINE_END_SEMANTIC(KaxTagTargets)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagSimple)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagName)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagLangue)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagDefault)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagString)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagBinary)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagSimple)
|
||||
DEFINE_END_SEMANTIC(KaxTagSimple)
|
||||
|
||||
DEFINE_MKX_MASTER (KaxTag, 0x7373, 2, KaxTags, "Tag");
|
||||
DEFINE_MKX_MASTER (KaxTagTargets, 0x63C0, 2, KaxTag, "TagTargets");
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagTargetTypeValue, 0x68CA, 2, KaxTagTargets, "TagTargetTypeValue", 50);
|
||||
DEFINE_MKX_STRING (KaxTagTargetType, 0x63CA, 2, KaxTagTargets, "TagTargetType");
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagTrackUID, 0x63C5, 2, KaxTagTargets, "TagTrackUID", 0);
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagEditionUID, 0x63C9, 2, KaxTagTargets, "TagEditionUID", 0);
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagChapterUID, 0x63C4, 2, KaxTagTargets, "TagChapterUID", 0);
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagAttachmentUID, 0x63C6, 2, KaxTagTargets, "TagAttachmentUID", 0);
|
||||
|
||||
DEFINE_MKX_MASTER (KaxTagSimple, 0x67C8, 2, KaxTag, "TagSimple");
|
||||
DEFINE_MKX_UNISTRING (KaxTagName, 0x45A3, 2, KaxTagSimple, "TagName");
|
||||
DEFINE_MKX_STRING_DEF (KaxTagLangue, 0x447A, 2, KaxTagSimple, "TagLanguage", "und");
|
||||
DEFINE_MKX_UINTEGER_DEF(KaxTagDefault, 0x4484, 2, KaxTagSimple, "TagDefault", 1);
|
||||
DEFINE_MKX_UNISTRING (KaxTagString, 0x4487, 2, KaxTagSimple, "TagString");
|
||||
DEFINE_MKX_BINARY (KaxTagBinary, 0x4485, 2, KaxTagSimple, "TagBinary");
|
||||
|
||||
END_LIBMATROSKA_NAMESPACE
|
||||
|
@ -1,212 +0,0 @@
|
||||
/****************************************************************************
|
||||
** libmatroska : parse Matroska files, see http://www.matroska.org/
|
||||
**
|
||||
** <file/class description>
|
||||
**
|
||||
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
|
||||
**
|
||||
** This file is part of libmatroska.
|
||||
**
|
||||
** This library is free software; you can redistribute it and/or
|
||||
** modify it under the terms of the GNU Lesser General Public
|
||||
** License as published by the Free Software Foundation; either
|
||||
** version 2.1 of the License, or (at your option) any later version.
|
||||
**
|
||||
** This library is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
** Lesser General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU Lesser General Public
|
||||
** License along with this library; if not, write to the Free Software
|
||||
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
**
|
||||
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
|
||||
** Contact license@matroska.org if any conditions of this licensing are
|
||||
** not clear to you.
|
||||
**
|
||||
**********************************************************************/
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id$
|
||||
\author Jory Stone <jcsston @ toughguy.net>
|
||||
\author Steve Lhomme <robux4 @ users.sf.net>
|
||||
*/
|
||||
#include "matroska/KaxTagMulti.h"
|
||||
#include "matroska/KaxContexts.h"
|
||||
#include "matroska/KaxDefines.h"
|
||||
|
||||
using namespace LIBEBML_NAMESPACE;
|
||||
|
||||
START_LIBMATROSKA_NAMESPACE
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiGlobal)
|
||||
// TODO: have the default EBML global semantic as well
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiComment)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiGlobal)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiComment)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiCommentName)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiCommentComments)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiCommentLanguage)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiComment)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiCommercial)
|
||||
DEFINE_SEMANTIC_ITEM(true, false, KaxTagCommercial)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiCommercial)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagCommercial)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagMultiCommercialType)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiCommercialAddress)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiCommercialURL)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiCommercialEmail)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiPrice)
|
||||
DEFINE_END_SEMANTIC(KaxTagCommercial)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiPrice)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiPriceCurrency)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiPriceAmount)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiPricePriceDate)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiPrice)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiDate)
|
||||
DEFINE_SEMANTIC_ITEM(true, false, KaxTagDate)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiDate)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagDate)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagMultiDateType)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiDateDateBegin)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiDateDateEnd)
|
||||
DEFINE_END_SEMANTIC(KaxTagDate)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiEntity)
|
||||
DEFINE_SEMANTIC_ITEM(true, false, KaxTagEntity)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiEntity)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagEntity)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagMultiEntityType)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiEntityName)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiEntityURL)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiEntityEmail)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiEntityAddress)
|
||||
DEFINE_END_SEMANTIC(KaxTagEntity)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiIdentifier)
|
||||
DEFINE_SEMANTIC_ITEM(true, false, KaxTagIdentifier)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiIdentifier)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagIdentifier)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagMultiIdentifierType)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiIdentifierBinary)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiIdentifierString)
|
||||
DEFINE_END_SEMANTIC(KaxTagIdentifier)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiLegal)
|
||||
DEFINE_SEMANTIC_ITEM(true, false, KaxTagLegal)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiLegal)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagLegal)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagMultiLegalType)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiLegalContent)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiLegalURL)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiLegalAddress)
|
||||
DEFINE_END_SEMANTIC(KaxTagLegal)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiTitle)
|
||||
DEFINE_SEMANTIC_ITEM(true, false, KaxTagTitle)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiTitle)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagTitle)
|
||||
DEFINE_SEMANTIC_ITEM(true, true, KaxTagMultiTitleType)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiTitleName)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiTitleSubTitle)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiTitleEdition)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiTitleAddress)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiTitleURL)
|
||||
DEFINE_SEMANTIC_ITEM(false, false, KaxTagMultiTitleEmail)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagMultiTitleLanguage)
|
||||
DEFINE_END_SEMANTIC(KaxTagTitle)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagMultiAttachment)
|
||||
DEFINE_SEMANTIC_ITEM(true, false, KaxTagAttachment)
|
||||
DEFINE_END_SEMANTIC(KaxTagMultiAttachment)
|
||||
|
||||
DEFINE_START_SEMANTIC(KaxTagAttachment)
|
||||
DEFINE_SEMANTIC_ITEM(false, true, KaxTagAttachmentID)
|
||||
DEFINE_END_SEMANTIC(KaxTagAttachment)
|
||||
|
||||
|
||||
DEFINE_MKX_CONTEXT(KaxTagMultiGlobal);
|
||||
|
||||
const EbmlSemanticContext & GetKaxTagsGlobal_Context()
|
||||
{
|
||||
return EBML_CLASS_SEMCONTEXT(KaxTagMultiGlobal);
|
||||
}
|
||||
|
||||
#if defined(HAVE_EBML2) || defined(HAS_EBML2)
|
||||
#define DEFINE_TAG_MASTER(a,b,c,d,e) DEFINE_xxx_MASTER(a,b,d,e,EBML_SemanticKaxTagMultiGlobal)
|
||||
#else
|
||||
#define DEFINE_TAG_MASTER(a,b,c,d,e) DEFINE_xxx_MASTER(a,b,c,d,e,*GetKaxTagsGlobal_Context)
|
||||
#endif
|
||||
|
||||
|
||||
DEFINE_MKX_MASTER (KaxTagMultiComment, 0x5B7B, 2, KaxTag, "MultiComment");
|
||||
DEFINE_MKX_STRING (KaxTagMultiCommentName, 0x5F7D, 2, KaxTagMultiComment, "MultiCommentName");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiCommentComments, 0x5F7C, 2, KaxTagMultiComment, "MultiCommentComments");
|
||||
DEFINE_MKX_STRING (KaxTagMultiCommentLanguage, 0x22B59D, 3, KaxTagMultiComment, "MultiCommentLanguage");
|
||||
|
||||
DEFINE_TAG_MASTER (KaxTagMultiCommercial, 0x4DC7, 2, KaxTag, "MultiCommercial");
|
||||
DEFINE_TAG_MASTER (KaxTagCommercial, 0x4EC7, 2, KaxTagMultiCommercial, "Commercial");
|
||||
DEFINE_MKX_UINTEGER (KaxTagMultiCommercialType, 0x5BD7, 2, KaxTagCommercial, "MultiCommercialType");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiCommercialAddress, 0x5BBB, 2, KaxTagCommercial, "MultiCommercialAddress");
|
||||
DEFINE_MKX_STRING (KaxTagMultiCommercialURL, 0x5BDA, 2, KaxTagCommercial, "MultiCommercialURL");
|
||||
DEFINE_MKX_STRING (KaxTagMultiCommercialEmail, 0x5BC0, 2, KaxTagCommercial, "MultiCommercialEmail");
|
||||
DEFINE_TAG_MASTER (KaxTagMultiPrice, 0x5BC3, 2, KaxTagCommercial, "MultiPrice");
|
||||
DEFINE_MKX_STRING (KaxTagMultiPriceCurrency, 0x5B6C, 2, KaxTagMultiPrice, "MultiPriceCurrency");
|
||||
DEFINE_MKX_FLOAT (KaxTagMultiPriceAmount, 0x5B6E, 2, KaxTagMultiPrice, "MultiPriceAmount");
|
||||
DEFINE_MKX_DATE (KaxTagMultiPricePriceDate, 0x5B6F, 2, KaxTagMultiPrice, "MultiPricePriceDate");
|
||||
|
||||
DEFINE_TAG_MASTER (KaxTagMultiDate, 0x4DC8, 2, KaxTag, "MultiDate");
|
||||
DEFINE_TAG_MASTER (KaxTagDate, 0x4EC8, 2, KaxTagMultiDate, "Date");
|
||||
DEFINE_MKX_UINTEGER (KaxTagMultiDateType, 0x5BD8, 2, KaxTagDate, "MultiDateType");
|
||||
DEFINE_MKX_DATE (KaxTagMultiDateDateBegin, 0x4460, 2, KaxTagDate, "MultiDateDateBegin");
|
||||
DEFINE_MKX_DATE (KaxTagMultiDateDateEnd, 0x4462, 2, KaxTagDate, "MultiDateDateEnd");
|
||||
|
||||
DEFINE_TAG_MASTER (KaxTagMultiEntity, 0x4DC9, 2, KaxTag, "MultiEntity");
|
||||
DEFINE_TAG_MASTER (KaxTagEntity, 0x4EC9, 2, KaxTagMultiEntity, "Entity");
|
||||
DEFINE_MKX_UINTEGER (KaxTagMultiEntityType, 0x5BD9, 2, KaxTagEntity, "MultiEntityType");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiEntityName, 0x5BED, 2, KaxTagEntity, "MultiEntityName");
|
||||
DEFINE_MKX_STRING (KaxTagMultiEntityURL, 0x5BDB, 2, KaxTagEntity, "MultiEntityURL");
|
||||
DEFINE_MKX_STRING (KaxTagMultiEntityEmail, 0x5BC1, 2, KaxTagEntity, "MultiEntityEmail");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiEntityAddress, 0x5BDC, 2, KaxTagEntity, "MultiEntityAddress");
|
||||
|
||||
DEFINE_TAG_MASTER (KaxTagMultiIdentifier, 0x4DC6, 2, KaxTag, "MultiIdentifier");
|
||||
DEFINE_TAG_MASTER (KaxTagIdentifier, 0x4EC6, 2, KaxTagMultiIdentifier, "Identifier");
|
||||
DEFINE_MKX_UINTEGER (KaxTagMultiIdentifierType, 0x5BAD, 2, KaxTagIdentifier, "MultiIdentifierType");
|
||||
DEFINE_MKX_BINARY (KaxTagMultiIdentifierBinary, 0x6B67, 2, KaxTagIdentifier, "MultiIdentifierBinary");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiIdentifierString, 0x6B68, 2, KaxTagIdentifier, "MultiIdentifierString");
|
||||
|
||||
DEFINE_TAG_MASTER (KaxTagMultiLegal, 0x4DC5, 2, KaxTag, "MultiLegal");
|
||||
DEFINE_TAG_MASTER (KaxTagLegal, 0x4EC5, 2, KaxTagMultiLegal, "Legal");
|
||||
DEFINE_MKX_UINTEGER (KaxTagMultiLegalType, 0x5BBD, 2, KaxTagLegal, "MultiLegalType");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiLegalContent, 0x5BB2, 2, KaxTagLegal, "MultiLegalContent");
|
||||
DEFINE_MKX_STRING (KaxTagMultiLegalURL, 0x5B34, 2, KaxTagLegal, "MultiLegalURL");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiLegalAddress, 0x5B9B, 2, KaxTagLegal, "MultiLegalAddress");
|
||||
|
||||
DEFINE_TAG_MASTER (KaxTagMultiTitle, 0x4DC4, 2, KaxTag, "MultiTitle");
|
||||
DEFINE_TAG_MASTER (KaxTagTitle, 0x4EC4, 2, KaxTagMultiTitle, "Title");
|
||||
DEFINE_MKX_UINTEGER (KaxTagMultiTitleType, 0x5B7D, 2, KaxTagTitle, "MultiTitleType");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiTitleName, 0x5BB9, 2, KaxTagTitle, "MultiTitleName");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiTitleSubTitle, 0x5B5B, 2, KaxTagTitle, "MultiTitleSubTitle");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiTitleEdition, 0x5BAE, 2, KaxTagTitle, "MultiTitleEdition");
|
||||
DEFINE_MKX_UNISTRING(KaxTagMultiTitleAddress, 0x5B33, 2, KaxTagTitle, "MultiTitleAddress");
|
||||
DEFINE_MKX_STRING (KaxTagMultiTitleURL, 0x5BA9, 2, KaxTagTitle, "MultiTitleURL");
|
||||
DEFINE_MKX_STRING (KaxTagMultiTitleEmail, 0x5BC9, 2, KaxTagTitle, "MultiTitleEmail");
|
||||
DEFINE_MKX_STRING (KaxTagMultiTitleLanguage, 0x22B59E, 3, KaxTagTitle, "MultiTitleLanguage");
|
||||
|
||||
DEFINE_TAG_MASTER (KaxTagMultiAttachment, 0x4DC3, 2, KaxTag, "MultiAttachment");
|
||||
DEFINE_TAG_MASTER (KaxTagAttachment, 0x4EC3, 2, KaxTagMultiAttachment, "Attachment");
|
||||
DEFINE_MKX_UINTEGER (KaxTagAttachmentID, 0x5BA0, 2, KaxTagAttachment, "AttachmentID");
|
||||
|
||||
END_LIBMATROSKA_NAMESPACE
|
@ -29,7 +29,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: test6.cpp 1078 2005-03-03 13:13:04Z robux4 $
|
||||
\version \$Id$
|
||||
\brief Test muxing two tracks into valid clusters/blocks/frames
|
||||
\author Steve Lhomme <robux4 @ users.sf.net>
|
||||
*/
|
||||
@ -125,7 +125,7 @@ int main(int argc, char **argv)
|
||||
*((EbmlUnicodeString *)&GetChild<KaxWritingApp>(MyInfos)) = L"éàôï";
|
||||
GetChild<KaxWritingApp>(MyInfos).SetDefaultSize(25);
|
||||
|
||||
uint32 InfoSize = MyInfos.Render(out_file);
|
||||
filepos_t InfoSize = MyInfos.Render(out_file);
|
||||
MetaSeek.IndexThis(MyInfos, FileSegment);
|
||||
|
||||
// fill track 1 params
|
||||
@ -301,7 +301,7 @@ int main(int argc, char **argv)
|
||||
Clust2.ReleaseFrames();
|
||||
|
||||
// older version, write at the end AllCues.Render(out_file);
|
||||
uint32 CueSize = AllCues.Render(out_file, bWriteDefaultValues);
|
||||
filepos_t CueSize = AllCues.Render(out_file, bWriteDefaultValues);
|
||||
MetaSeek.IndexThis(AllCues, FileSegment);
|
||||
|
||||
// Chapters
|
||||
@ -332,7 +332,7 @@ int main(int argc, char **argv)
|
||||
KaxChapterLanguage & aChapLang2 = GetChild<KaxChapterLanguage>(aDisplay2);
|
||||
*static_cast<EbmlString *>(&aChapLang2) = "eng";
|
||||
|
||||
uint32 ChapterSize = Chapters.Render(out_file, bWriteDefaultValues);
|
||||
filepos_t ChapterSize = Chapters.Render(out_file, bWriteDefaultValues);
|
||||
MetaSeek.IndexThis(Chapters, FileSegment);
|
||||
|
||||
// Write some tags
|
||||
@ -348,34 +348,20 @@ int main(int argc, char **argv)
|
||||
KaxTagChapterUID & ChapterUID = GetChild<KaxTagChapterUID>(Targets);
|
||||
*static_cast<EbmlUInteger *>(&ChapterUID) = 0x67890;
|
||||
|
||||
#if 0
|
||||
KaxTagSubject & Subject = GetChild<KaxTagSubject>(TagGeneral);
|
||||
*static_cast<EbmlUnicodeString *>(&Subject) = L"Testé123";
|
||||
|
||||
KaxTagBibliography & Biblio = GetChild<KaxTagBibliography>(TagGeneral);
|
||||
*static_cast<EbmlUnicodeString *>(&Biblio) = L"ça marche";
|
||||
|
||||
KaxTagFile & File = GetChild<KaxTagFile>(TagGeneral);
|
||||
*static_cast<EbmlUnicodeString *>(&File) = L"Fichier";
|
||||
|
||||
KaxTagLanguage & Lang = GetChild<KaxTagLanguage>(TagGeneral);
|
||||
*static_cast<EbmlString *>(&Lang) = "fra";
|
||||
#else
|
||||
KaxTagName & aTagName = GetChild<KaxTagName>(TagSimple);
|
||||
*static_cast<EbmlUnicodeString *>(&aTagName) = L"NAME";
|
||||
|
||||
KaxTagString & aTagtring = GetChild<KaxTagString>(TagSimple);
|
||||
*static_cast<EbmlUnicodeString *>(&aTagtring) = L"Testé123";
|
||||
#endif
|
||||
|
||||
uint32 TagsSize = AllTags.Render(out_file, bWriteDefaultValues);
|
||||
filepos_t TagsSize = AllTags.Render(out_file, bWriteDefaultValues);
|
||||
MetaSeek.IndexThis(AllTags, FileSegment);
|
||||
|
||||
TrackSize += pMyTracks2->Render(out_file, bWriteDefaultValues);
|
||||
MetaSeek.IndexThis(*pMyTracks2, FileSegment);
|
||||
|
||||
// \todo put it just before the Cue Entries
|
||||
uint32 MetaSeekSize = Dummy.ReplaceWith(MetaSeek, out_file, bWriteDefaultValues);
|
||||
filepos_t MetaSeekSize = Dummy.ReplaceWith(MetaSeek, out_file, bWriteDefaultValues);
|
||||
|
||||
#ifdef VOID_TEST
|
||||
MyInfos.VoidMe(out_file);
|
||||
|
@ -27,7 +27,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: test8.cpp 675 2004-07-27 07:56:14Z mosu $
|
||||
\version \$Id$
|
||||
\brief Test reading of the Header
|
||||
\author Steve Lhomme <robux4 @ users.sf.net>
|
||||
*/
|
||||
@ -59,7 +59,6 @@
|
||||
#include "matroska/KaxChapters.h"
|
||||
#include "matroska/KaxTags.h"
|
||||
#include "matroska/KaxTag.h"
|
||||
#include "matroska/KaxTagMulti.h"
|
||||
#include "ebml/StdIOCallback.h"
|
||||
|
||||
using namespace LIBMATROSKA_NAMESPACE;
|
||||
@ -656,6 +655,7 @@ int main(int argc, char **argv)
|
||||
#endif // TEST_REMOVE
|
||||
} else if (Targets[Index2]->Generic().GlobalId == KaxTagChapterUID::ClassInfos.GlobalId) {
|
||||
printf(" Chapter UID\n");
|
||||
#if 0
|
||||
} else if (Targets[Index2]->Generic().GlobalId == KaxTagMultiComment::ClassInfos.GlobalId) {
|
||||
printf(" Comment\n");
|
||||
KaxTagMultiComment & Comment = *static_cast<KaxTagMultiComment *>(Targets[Index2]);
|
||||
@ -667,6 +667,7 @@ int main(int argc, char **argv)
|
||||
}
|
||||
}
|
||||
// } else if (Targets[Index2]->Generic().GlobalId == DummyRawElement::ClassInfos.GlobalId) {
|
||||
#endif
|
||||
}
|
||||
}
|
||||
#ifdef TEST_REMOVE
|
||||
@ -677,6 +678,7 @@ int main(int argc, char **argv)
|
||||
printf(" -- Done --\n");
|
||||
}
|
||||
#endif // TEST_REMOVE
|
||||
#if 0
|
||||
} else if (TagElt[Index1]->Generic().GlobalId == KaxTagGeneral::ClassInfos.GlobalId) {
|
||||
printf(" General\n");
|
||||
KaxTagGeneral & General = *static_cast<KaxTagGeneral *>(TagElt[Index1]);
|
||||
@ -729,6 +731,7 @@ int main(int argc, char **argv)
|
||||
printf(" Comment Name \"%s\"\n", std::string(CommentName).c_str());
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user