Can now handle NIT and TOT from SIS.
All checks were successful
🚀 Pack skyscraper8 / make-zip (push) Successful in 2m14s

This commit is contained in:
Fey 2025-12-15 23:04:20 +01:00
parent 3b0dad4ba5
commit 6c813f596b
6 changed files with 55 additions and 7 deletions

View File

@ -28,6 +28,11 @@ namespace skyscraper8.DvbSis
{ {
} }
public void OnSisNit(int sourcePid, SisNitContainer nitContainer)
{
}
public void OnSisPat(int sourcePid, SisPatContainer patContainer) public void OnSisPat(int sourcePid, SisPatContainer patContainer)
{ {
} }
@ -48,5 +53,9 @@ namespace skyscraper8.DvbSis
public void OnSisTimestamp(int pid, _0x20_DvbT2Timestamp t2Timestamp) public void OnSisTimestamp(int pid, _0x20_DvbT2Timestamp t2Timestamp)
{ {
} }
public void OnSisTot(int sourcePid, SisTotContainer totContainer)
{
}
} }
} }

View File

@ -14,10 +14,12 @@ namespace skyscraper8.DvbSis
void OnSisDsaci(ushort currentDsaGroupId, int versionNumber, byte sectionNumber, byte lastSectionNumber, Stream dsaci); void OnSisDsaci(ushort currentDsaGroupId, int versionNumber, byte sectionNumber, byte lastSectionNumber, Stream dsaci);
void OnSisEit(int sourcePid, SisEitContainer eitContainer); void OnSisEit(int sourcePid, SisEitContainer eitContainer);
void OnSisFti(int relatedPid, _0xF0_FramingTimingInformation fti); void OnSisFti(int relatedPid, _0xF0_FramingTimingInformation fti);
void OnSisNit(int sourcePid, SisNitContainer nitContainer);
void OnSisPat(int sourcePid, SisPatContainer patContainer); void OnSisPat(int sourcePid, SisPatContainer patContainer);
void OnSisPmt(int sourcePid, SisPmtContainer pmtContainer); void OnSisPmt(int sourcePid, SisPmtContainer pmtContainer);
void OnSisSdt(int sourcePid, SisSdtContainer sdtContainer); void OnSisSdt(int sourcePid, SisSdtContainer sdtContainer);
void OnSisTdt(int sourcePid, SisTdtContainer tdtContainer); void OnSisTdt(int sourcePid, SisTdtContainer tdtContainer);
void OnSisTimestamp(int pid, _0x20_DvbT2Timestamp t2Timestamp); void OnSisTimestamp(int pid, _0x20_DvbT2Timestamp t2Timestamp);
void OnSisTot(int sourcePid, SisTotContainer totContainer);
} }
} }

View File

@ -41,7 +41,11 @@ namespace skyscraper8.DvbSis
_handler.OnSisPmt(sourcePid, pmtContainer); _handler.OnSisPmt(sourcePid, pmtContainer);
break; break;
case 0x40: case 0x40:
SisNitContainer nitContainer = new SisNitContainer();
NitParser nitParser = new NitParser(nitContainer);
nitParser.GatherPsi(section, 0);
_handler.OnSisNit(sourcePid, nitContainer);
break;
case 0x42: case 0x42:
SisSdtContainer sdtContainer = new SisSdtContainer(); SisSdtContainer sdtContainer = new SisSdtContainer();
SdtParser sdtParser = new SdtParser(sdtContainer); SdtParser sdtParser = new SdtParser(sdtContainer);
@ -61,6 +65,12 @@ namespace skyscraper8.DvbSis
tdtParser.GatherPsi(section, sourcePid); tdtParser.GatherPsi(section, sourcePid);
_handler.OnSisTdt(sourcePid, tdtContainer); _handler.OnSisTdt(sourcePid, tdtContainer);
break; break;
case 0x73:
SisTotContainer totContainer = new SisTotContainer();
TimetableParser totParser = new TimetableParser(null, totContainer);
totParser.GatherPsi(section, sourcePid);
_handler.OnSisTot(sourcePid, totContainer);
break;
default: default:
throw new NotImplementedException(String.Format("Table ID 0x{0:X2} in DVB-SIS PSI/SI not supported yet. To get this fixed, please share a sample of this stream.", section.TableId)); throw new NotImplementedException(String.Format("Table ID 0x{0:X2} in DVB-SIS PSI/SI not supported yet. To get this fixed, please share a sample of this stream.", section.TableId));
} }

View File

@ -0,0 +1,22 @@
using skyscraper5.Dvb.Descriptors;
using skyscraper5.Dvb.Psi;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace skyscraper8.DvbSis
{
internal class SisTotContainer : ITotEventHandler
{
public DateTime UtcTime { get; private set; }
public LocalTimeOffsetDescriptor LocalTimeOffset { get; private set; }
public void OnTotTime(DateTime utcTime, LocalTimeOffsetDescriptor ltod)
{
this.UtcTime = utcTime;
this.LocalTimeOffset = ltod;
}
}
}

View File

@ -2,7 +2,7 @@
"profiles": { "profiles": {
"skyscraper8": { "skyscraper8": {
"commandName": "Project", "commandName": "Project",
"commandLineArgs": "\"F:\\utena2\\dvb-sis_eutelsat5_12522_v.ts\"", "commandLineArgs": "\"F:\\utena2\\dvb-sis_badr_12563v.ts\"",
"remoteDebugEnabled": false "remoteDebugEnabled": false
}, },
"Container (Dockerfile)": { "Container (Dockerfile)": {

View File

@ -590,6 +590,11 @@ namespace skyscraper5.Skyscraper.Scraper
DvbContext.RegisterPacketProcessor(mappingStream.ElementaryPid, videoPacketProcessor); DvbContext.RegisterPacketProcessor(mappingStream.ElementaryPid, videoPacketProcessor);
} }
if (!DvbContext.IsPidProcessorPresent(mappingStream.ElementaryPid))
{
DvbContext.RegisterPacketProcessor(mappingStream.ElementaryPid, new PacketDiscarder());
}
break; break;
case StreamType.Teletext: case StreamType.Teletext:
if (!CurrentNetworkId.HasValue) if (!CurrentNetworkId.HasValue)