|
|
|
@ -121,7 +121,7 @@ namespace MediaBrowser.Server.Implementations.Persistence
|
|
|
|
|
_connection = await SqliteExtensions.ConnectToDb(dbFile, _logger).ConfigureAwait(false);
|
|
|
|
|
|
|
|
|
|
var createMediaStreamsTableCommand
|
|
|
|
|
= "create table if not exists mediastreams (ItemId GUID, StreamIndex INT, StreamType TEXT, Codec TEXT, Language TEXT, ChannelLayout TEXT, Profile TEXT, AspectRatio TEXT, Path TEXT, IsInterlaced BIT, BitRate INT NULL, Channels INT NULL, SampleRate INT NULL, IsDefault BIT, IsForced BIT, IsExternal BIT, Height INT NULL, Width INT NULL, AverageFrameRate FLOAT NULL, RealFrameRate FLOAT NULL, Level FLOAT NULL, PixelFormat TEXT, BitDepth INT NULL, IsAnamorphic BIT NULL, RefFrames INT NULL, IsCabac BIT NULL, KeyFrames TEXT NULL, PRIMARY KEY (ItemId, StreamIndex))";
|
|
|
|
|
= "create table if not exists mediastreams (ItemId GUID, StreamIndex INT, StreamType TEXT, Codec TEXT, Language TEXT, ChannelLayout TEXT, Profile TEXT, AspectRatio TEXT, Path TEXT, IsInterlaced BIT, BitRate INT NULL, Channels INT NULL, SampleRate INT NULL, IsDefault BIT, IsForced BIT, IsExternal BIT, Height INT NULL, Width INT NULL, AverageFrameRate FLOAT NULL, RealFrameRate FLOAT NULL, Level FLOAT NULL, PixelFormat TEXT, BitDepth INT NULL, IsAnamorphic BIT NULL, RefFrames INT NULL, IsCabac BIT NULL, KeyFrames TEXT NULL, CodecTag TEXT NULL, PRIMARY KEY (ItemId, StreamIndex))";
|
|
|
|
|
|
|
|
|
|
string[] queries = {
|
|
|
|
|
|
|
|
|
@ -320,7 +320,8 @@ namespace MediaBrowser.Server.Implementations.Persistence
|
|
|
|
|
"IsAnamorphic",
|
|
|
|
|
"RefFrames",
|
|
|
|
|
"IsCabac",
|
|
|
|
|
"KeyFrames"
|
|
|
|
|
"KeyFrames",
|
|
|
|
|
"CodecTag"
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
@ -2209,6 +2210,8 @@ namespace MediaBrowser.Server.Implementations.Persistence
|
|
|
|
|
_saveStreamCommand.GetParameter(index++).Value = string.Join(",", stream.KeyFrames.Select(i => i.ToString(CultureInfo.InvariantCulture)).ToArray());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
_saveStreamCommand.GetParameter(index++).Value = stream.CodecTag;
|
|
|
|
|
|
|
|
|
|
_saveStreamCommand.Transaction = transaction;
|
|
|
|
|
_saveStreamCommand.ExecuteNonQuery();
|
|
|
|
|
}
|
|
|
|
@ -2370,6 +2373,11 @@ namespace MediaBrowser.Server.Implementations.Persistence
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (!reader.IsDBNull(27))
|
|
|
|
|
{
|
|
|
|
|
item.CodecTag = reader.GetString(27);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return item;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|