Working on dvb sub

git-svn-id: https://subtitleedit.googlecode.com/svn/trunk@2361 99eadd0c-20b8-1223-b5c4-2a2b2df33de2
This commit is contained in:
niksedk 2014-01-10 14:29:39 +00:00
parent 5d64498a44
commit 57f5f06c8f
2 changed files with 3 additions and 5 deletions

View File

@ -276,20 +276,19 @@ namespace Nikse.SubtitleEdit.Logic.TransportStream
}
}
Bitmap bmp = new Bitmap(width, height);
var bmp = new Bitmap(width, height);
foreach (ObjectDataSegment ods in ObjectDataList)
{
Bitmap odsImage = GetImage(ods);
if (odsImage != null)
{
Point odsPoint = GetImagePosition(ods);
using (Graphics g = Graphics.FromImage(bmp))
using (var g = Graphics.FromImage(bmp))
{
g.DrawImageUnscaled(odsImage, odsPoint);
}
}
}
return bmp;
}
@ -330,7 +329,7 @@ namespace Nikse.SubtitleEdit.Logic.TransportStream
public ulong PresentationTimeStampToMilliseconds()
{
if (PresentationTimeStamp.HasValue)
return (ulong)Math.Round(PresentationTimeStamp.Value + 45.0 / 90.0);
return (ulong)Math.Round((PresentationTimeStamp.Value + 45.0) / 90.0);
else
return 0;
}

View File

@ -1062,7 +1062,6 @@
<Compile Include="Logic\TransportStream\HummingDecoder.cs" />
<Compile Include="Logic\TransportStream\ObjectDataSegment.cs" />
<Compile Include="Logic\TransportStream\Packet.cs" />
<Compile Include="Logic\TransportStream\PacketizedElementaryStream.cs" />
<Compile Include="Logic\TransportStream\PageCompositionSegemnt.cs" />
<Compile Include="Logic\TransportStream\PageCompositionSegmentRegion.cs" />
<Compile Include="Logic\TransportStream\ProgramAssociationTable.cs" />