You've already forked libopenshot
mirror of
https://github.com/OpenShot/libopenshot.git
synced 2026-03-02 08:53:52 -08:00
Additional testing changes
This commit is contained in:
40
src/Main.cpp
40
src/Main.cpp
@@ -21,8 +21,8 @@ int main()
|
||||
// openshot::FFmpegReader r("/home/jonathan/Videos/big-buck-bunny_trailer.webm");
|
||||
|
||||
// openshot::FFmpegReader r("/home/jonathan/Videos/sintel-1024-stereo.mp4");
|
||||
// openshot::FFmpegReader r("/home/jonathan/Videos/OpenShot_Now_In_3d.mp4");
|
||||
openshot::FFmpegReader r("/home/jonathan/Videos/sintel_trailer-720p.mp4");
|
||||
openshot::FFmpegReader r("/home/jonathan/Videos/OpenShot_Now_In_3d.mp4");
|
||||
// openshot::FFmpegReader r("/home/jonathan/Videos/sintel_trailer-720p.mp4");
|
||||
// openshot::FFmpegReader r("/home/jonathan/Aptana Studio Workspace/OpenShotLibrary/src/examples/piano.wav");
|
||||
// openshot::FFmpegReader r("/home/jonathan/Music/Army of Lovers/Crucified/Army of Lovers - Crucified [Single Version].mp3");
|
||||
// openshot::FFmpegReader r("/home/jonathan/Documents/OpenShot Art/test.jpeg");
|
||||
@@ -33,31 +33,31 @@ int main()
|
||||
r.DisplayInfo();
|
||||
|
||||
// Create a writer
|
||||
FFmpegWriter w("/home/jonathan/output.mp3");
|
||||
FFmpegWriter w("/home/jonathan/output.webm");
|
||||
w.DisplayInfo();
|
||||
|
||||
// Set options
|
||||
w.SetAudioOptions(true, "libmp3lame", 44100, 2, 128000);
|
||||
//w.SetVideoOptions(true, "libvpx", Fraction(24, 1), 640, 360, Fraction(1,1), false, false, 2000000);
|
||||
w.SetAudioOptions(true, "libvorbis", 44100, 2, 128000);
|
||||
w.SetVideoOptions(true, "libvpx", Fraction(24, 1), 640, 360, Fraction(1,1), false, false, 2000000);
|
||||
|
||||
// Prepare Streams
|
||||
w.PrepareStreams();
|
||||
|
||||
// Set Options
|
||||
// w.SetOption(VIDEO_STREAM, "quality", "good");
|
||||
// w.SetOption(VIDEO_STREAM, "g", "120");
|
||||
// w.SetOption(VIDEO_STREAM, "qmin", "11");
|
||||
// w.SetOption(VIDEO_STREAM, "qmax", "51");
|
||||
// w.SetOption(VIDEO_STREAM, "profile", "0");
|
||||
// w.SetOption(VIDEO_STREAM, "speed", "0");
|
||||
// w.SetOption(VIDEO_STREAM, "level", "216");
|
||||
// w.SetOption(VIDEO_STREAM, "rc_lookahead", "16");
|
||||
// w.SetOption(VIDEO_STREAM, "rc_min_rate", "100000");
|
||||
// w.SetOption(VIDEO_STREAM, "rc_max_rate", "24000000");
|
||||
// w.SetOption(VIDEO_STREAM, "slices", "4");
|
||||
// w.SetOption(VIDEO_STREAM, "arnr_max_frames", "7");
|
||||
// w.SetOption(VIDEO_STREAM, "arnr_strength", "5");
|
||||
// w.SetOption(VIDEO_STREAM, "arnr_type", "3");
|
||||
w.SetOption(VIDEO_STREAM, "quality", "good");
|
||||
w.SetOption(VIDEO_STREAM, "g", "120");
|
||||
w.SetOption(VIDEO_STREAM, "qmin", "11");
|
||||
w.SetOption(VIDEO_STREAM, "qmax", "51");
|
||||
w.SetOption(VIDEO_STREAM, "profile", "0");
|
||||
w.SetOption(VIDEO_STREAM, "speed", "0");
|
||||
w.SetOption(VIDEO_STREAM, "level", "216");
|
||||
w.SetOption(VIDEO_STREAM, "rc_lookahead", "16");
|
||||
w.SetOption(VIDEO_STREAM, "rc_min_rate", "100000");
|
||||
w.SetOption(VIDEO_STREAM, "rc_max_rate", "24000000");
|
||||
w.SetOption(VIDEO_STREAM, "slices", "4");
|
||||
w.SetOption(VIDEO_STREAM, "arnr_max_frames", "7");
|
||||
w.SetOption(VIDEO_STREAM, "arnr_strength", "5");
|
||||
w.SetOption(VIDEO_STREAM, "arnr_type", "3");
|
||||
|
||||
// Write header
|
||||
w.WriteHeader();
|
||||
@@ -67,7 +67,7 @@ int main()
|
||||
|
||||
//Frame *f = r.GetFrame(1);
|
||||
|
||||
for (int frame = 1; frame <= 500; frame++)
|
||||
for (int frame = 1; frame <= 1000; frame++)
|
||||
{
|
||||
Frame *f = r.GetFrame(frame);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user