diff --git a/FFMpegCore/FFMPEG/Argument/Atoms/InputPipeArgument.cs b/FFMpegCore/FFMPEG/Argument/Atoms/InputPipeArgument.cs
index ee6b19b..cd818d8 100644
--- a/FFMpegCore/FFMPEG/Argument/Atoms/InputPipeArgument.cs
+++ b/FFMpegCore/FFMPEG/Argument/Atoms/InputPipeArgument.cs
@@ -17,11 +17,11 @@ public class InputPipeArgument : Argument
{
public string PipeName { get; private set; }
public string PipePath => PipeHelpers.GetPipePath(PipeName);
- public IPipeSource Source { get; private set; }
+ public IPipeDataWriter Source { get; private set; }
private NamedPipeServerStream pipe;
- public InputPipeArgument(IPipeSource source)
+ public InputPipeArgument(IPipeDataWriter source)
{
Source = source;
PipeName = PipeHelpers.GetUnqiuePipeName();
@@ -49,14 +49,14 @@ public override string GetStringValue()
public void FlushPipe()
{
pipe.WaitForConnection();
- Source.FlushData(pipe);
+ Source.WriteData(pipe);
}
public async Task FlushPipeAsync()
{
await pipe.WaitForConnectionAsync();
- await Source.FlushDataAsync(pipe);
+ await Source.WriteDataAsync(pipe);
}
}
}
diff --git a/FFMpegCore/FFMPEG/Pipes/IPipeSource.cs b/FFMpegCore/FFMPEG/Pipes/IPipeDataWriter.cs
similarity index 68%
rename from FFMpegCore/FFMPEG/Pipes/IPipeSource.cs
rename to FFMpegCore/FFMPEG/Pipes/IPipeDataWriter.cs
index 80d3ddf..aa4bbc8 100644
--- a/FFMpegCore/FFMPEG/Pipes/IPipeSource.cs
+++ b/FFMpegCore/FFMPEG/Pipes/IPipeDataWriter.cs
@@ -9,10 +9,10 @@ namespace FFMpegCore.FFMPEG.Pipes
///
/// Interface for ffmpeg pipe source data IO
///
- public interface IPipeSource
+ public interface IPipeDataWriter
{
string GetFormat();
- void FlushData(System.IO.Stream pipe);
- Task FlushDataAsync(System.IO.Stream pipe);
+ void WriteData(System.IO.Stream pipe);
+ Task WriteDataAsync(System.IO.Stream pipe);
}
}
diff --git a/FFMpegCore/FFMPEG/Pipes/RawVideoPipeSource.cs b/FFMpegCore/FFMPEG/Pipes/RawVideoPipeDataWriter.cs
similarity index 77%
rename from FFMpegCore/FFMPEG/Pipes/RawVideoPipeSource.cs
rename to FFMpegCore/FFMPEG/Pipes/RawVideoPipeDataWriter.cs
index c6f3b27..c7d3df0 100644
--- a/FFMpegCore/FFMPEG/Pipes/RawVideoPipeSource.cs
+++ b/FFMpegCore/FFMPEG/Pipes/RawVideoPipeDataWriter.cs
@@ -7,9 +7,9 @@
namespace FFMpegCore.FFMPEG.Pipes
{
///
- /// Implementation of for a raw video stream that is gathered from
+ /// Implementation of for a raw video stream that is gathered from
///
- public class RawVideoPipeSource : IPipeSource
+ public class RawVideoPipeDataWriter : IPipeDataWriter
{
public string StreamFormat { get; set; }
public int Width { get; set; }
@@ -17,12 +17,12 @@ public class RawVideoPipeSource : IPipeSource
public int FrameRate { get; set; } = 25;
private IEnumerator framesEnumerator;
- public RawVideoPipeSource(IEnumerator framesEnumerator)
+ public RawVideoPipeDataWriter(IEnumerator framesEnumerator)
{
this.framesEnumerator = framesEnumerator;
}
- public RawVideoPipeSource(IEnumerable framesEnumerator) : this(framesEnumerator.GetEnumerator()) { }
+ public RawVideoPipeDataWriter(IEnumerable framesEnumerator) : this(framesEnumerator.GetEnumerator()) { }
public string GetFormat()
{
@@ -40,7 +40,7 @@ public string GetFormat()
return $"-f rawvideo -r {FrameRate} -pix_fmt {StreamFormat} -s {Width}x{Height}";
}
- public void FlushData(System.IO.Stream stream)
+ public void WriteData(System.IO.Stream stream)
{
if (framesEnumerator.Current != null)
{
@@ -53,7 +53,7 @@ public void FlushData(System.IO.Stream stream)
}
}
- public async Task FlushDataAsync(System.IO.Stream stream)
+ public async Task WriteDataAsync(System.IO.Stream stream)
{
if (framesEnumerator.Current != null)
{
diff --git a/FFMpegCore/FFMPEG/Pipes/StreamPipeDataReader.cs b/FFMpegCore/FFMPEG/Pipes/StreamPipeDataReader.cs
index c59a475..d080806 100644
--- a/FFMpegCore/FFMPEG/Pipes/StreamPipeDataReader.cs
+++ b/FFMpegCore/FFMPEG/Pipes/StreamPipeDataReader.cs
@@ -5,12 +5,12 @@
namespace FFMpegCore.FFMPEG.Pipes
{
- public class StreamPipedataReader : IPipeDataReader
+ public class StreamPipeDataReader : IPipeDataReader
{
public System.IO.Stream DestanationStream { get; private set; }
public int BlockSize { get; set; } = 4096;
- public StreamPipedataReader(System.IO. Stream destanationStream)
+ public StreamPipeDataReader(System.IO. Stream destanationStream)
{
DestanationStream = destanationStream;
}
diff --git a/FFMpegCore/FFMPEG/Pipes/StreamPipeSource.cs b/FFMpegCore/FFMPEG/Pipes/StreamPipeDataWriter.cs
similarity index 74%
rename from FFMpegCore/FFMPEG/Pipes/StreamPipeSource.cs
rename to FFMpegCore/FFMPEG/Pipes/StreamPipeDataWriter.cs
index 1028562..441a28f 100644
--- a/FFMpegCore/FFMPEG/Pipes/StreamPipeSource.cs
+++ b/FFMpegCore/FFMPEG/Pipes/StreamPipeDataWriter.cs
@@ -6,19 +6,19 @@
namespace FFMpegCore.FFMPEG.Pipes
{
///
- /// Implementation of used for stream redirection
+ /// Implementation of used for stream redirection
///
- public class StreamPipeSource : IPipeSource
+ public class StreamPipeDataWriter : IPipeDataWriter
{
public System.IO.Stream Source { get; private set; }
public int BlockSize { get; set; } = 4096;
- public StreamPipeSource(System.IO.Stream stream)
+ public StreamPipeDataWriter(System.IO.Stream stream)
{
Source = stream;
}
- public void FlushData(System.IO.Stream pipe)
+ public void WriteData(System.IO.Stream pipe)
{
var buffer = new byte[BlockSize];
int read;
@@ -28,7 +28,7 @@ public void FlushData(System.IO.Stream pipe)
}
}
- public async Task FlushDataAsync(System.IO.Stream pipe)
+ public async Task WriteDataAsync(System.IO.Stream pipe)
{
var buffer = new byte[BlockSize];
int read;