C# Class HCS_Encoder.Outputs.SmoothStream.ChunkTransformer

Inheritance: IOutputHandler
ファイルを表示 Open project: i-e-b/HLS---Smooth-Encoder Class Usage Examples

Private Properties

Property Type Description
ConnectAndPushHeaders void
PreparePointCreator IisPointCreator
PreparePublishingPoint void
PrepareTransformer void
PushStream void
SanitiseStream void
Transform void

Public Methods

Method Description
ChunkTransformer ( EncoderConfiguration Configuration, bool pubPointCreationIsOptional ) : System

Create a new chunk transformer. Will try to create a new IIS Live Smooth Streaming publishing point matching the configuration settings. Will try both WebDAV and FTP. If neither are not correctly enabled on the destination server, the point must already exist.

Close ( ) : void

Shut down the streams and close connections.

ConsumeChunk ( int ChunkIndex, int StreamIndex, string FilePath, double chunkDuration ) : void
GetStreamMappingType ( ) : StreamMapping
OnFileConsumed ( object sender, System.IO.FileEventArgs args ) : void
Prepare ( List Packages ) : void

Protected Methods

Method Description
UploadAction ( object o ) : void

Private Methods

Method Description
ConnectAndPushHeaders ( MediaStream stream, FileRoot TargetMp4fFile ) : void

Used once per connection, this opens a long-life HTTP stream and pushes the very basic MP4 parts needed to get IIS working.

PreparePointCreator ( string dest_root ) : IisPointCreator
PreparePublishingPoint ( EncoderConfiguration Configuration ) : void
PrepareTransformer ( EncoderConfiguration Configuration, List Packages ) : void

Read the supplied configuration and prepare the transformer for work.

PushStream ( MediaStream stream, FileRoot TargetMp4fFile ) : void

Pushes a set of frames to IIS. Will trigger a connect if needed.

SanitiseStream ( MediaStream stream ) : void

Remove any frames with zero length. Zero length frames kill the live stream.

Transform ( string SourceFile, int StreamIndex, int ChunkIndex ) : void

Transform an MPEG-TS file into a MP4f file. This all needs to be stripped out and each stream needs it's own IisSmoothPush connection.

Method Details

ChunkTransformer() public method

Create a new chunk transformer. Will try to create a new IIS Live Smooth Streaming publishing point matching the configuration settings. Will try both WebDAV and FTP. If neither are not correctly enabled on the destination server, the point must already exist.
public ChunkTransformer ( EncoderConfiguration Configuration, bool pubPointCreationIsOptional ) : System
Configuration EncoderConfiguration
pubPointCreationIsOptional bool
return System

Close() public method

Shut down the streams and close connections.
public Close ( ) : void
return void

ConsumeChunk() public method

public ConsumeChunk ( int ChunkIndex, int StreamIndex, string FilePath, double chunkDuration ) : void
ChunkIndex int
StreamIndex int
FilePath string
chunkDuration double
return void

GetStreamMappingType() public method

public GetStreamMappingType ( ) : StreamMapping
return StreamMapping

OnFileConsumed() public method

public OnFileConsumed ( object sender, System.IO.FileEventArgs args ) : void
sender object
args System.IO.FileEventArgs
return void

Prepare() public method

public Prepare ( List Packages ) : void
Packages List
return void

UploadAction() protected method

protected UploadAction ( object o ) : void
o object
return void