Log in

View Full Version : Simple x264/x265 Launcher v3.02 (2022-06-16)


Pages : 1 2 3 4 5 6 7 8 9 10 11 12 13 [14] 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40

VideoFanatic
20th February 2012, 16:18
I don't know what you mean! I didn't even understand the calculation you did before! I did some searching and all I found was people equally confused about this issue.

Wouldn't it be easier to just have a checkbox in your program to select 4:3 or 16:9?

LoRd_MuldeR
20th February 2012, 16:37
I don't know what you mean! I didn't even understand the calculation you did before! I did some searching and all I found was people equally confused about this issue.

Hit F5 and you'll see the result of the calculation. Hopefully you will be able to solve it yourself next time.

Wouldn't it be easier to just have a checkbox in your program to select 4:3 or 16:9?

Nope. Because we need to enter the SAR (Sample Aspect Ratio, aka Pixel Aspect Ratio), and not the DAR (Display Aspect Ratio).

For the same DAR (e.g. 4:3 or 16:9) a completely different SAR may be required. It depends on the resolution of the video.

For 720x480 (NTSC) video a SAR of 8:9 results in a DAR of 4:3, as desired. But for 720x576 (PAL) a different SAR would be required to get the same DAR of 4:3.

Also 4:3 and 16:9 are not the only DAR's in existence. These are commonly used in TV Broadcast, yes. But other DAR's may be used just as well.

Actually video intended to watch on a computer as well as all "HD" video (1080p, 720p, etc) usually uses a SAR of 1:1, aka "Square Pixels".

Non-Square Pixels, aka "Anamorphic Video", aka SAR ≠ 1:1, is only a reminiscent of the analogous TV era...

VideoFanatic
20th February 2012, 17:11
OK fair enough but why would HC Encoder have a 4:3 option if it didn't give the intended result on 720 x 480 NTSC and 720 x 576 PAL?

LoRd_MuldeR
20th February 2012, 17:15
OK fair enough but why would HC Encoder have a 4:3 option if it didn't give the intended result on 720 x 480 NTSC and 720 x 576 PAL?

It probably calculates the required SAR from the chosen DAR and the actual resolution of the input video.

Simple x264 Launcher is just a front-end to the x264 CLI encoder. It doesn't know the exact resolution of the input video beforehand.

And therefore it cannot calculate the required SAR (for the desired DAR) from the information it has available...

I'm still lost as to what setting I'm supposed to use to get 16:9. What am I supposed to type into my calculator and where do I get the values from?

The calculation is straight forward. And I even gave you a detailed example above.

But to say it again: For 720x480 video you'll have to enter a SAR of 32:27 in order to get a DAR of 16:9.

VideoFanatic
20th February 2012, 17:17
I'm still lost as to what setting I'm supposed to use to get 16:9. What am I supposed to type into my calculator and where do I get the values from?

LoRd_MuldeR
20th February 2012, 17:25
Well, we know that "Width:Height x SAR = DAR". Width, Height and DAR are known. SAR we want to know.

So you write on a piece of paper "720:480 x X = 16:9" and then you solve what X is, like you (hopefully) learned it back in elementary school.

You will see that "X = 16:9 x 480:720 = (16x480):(9x720)". So you can type that into your calculator, if you are too lazy to reduce the fraction to 32:27 by hand...

Or you let WolframAlpha do the work:
http://www.wolframalpha.com/input/?i=Solve+%28720%2F480%29+*+X+%3D+16%2F9

reff24
20th February 2012, 19:38
You can add any configuration on a menu item? Loading template (Custom Matrix)?

they have overlooked it in their discussion with holygamer perhaps. Is it possible to install it?

SeeMoreDigital
20th February 2012, 20:03
By any chance. Is there anybody here able to provide a Quicktime player friendly "Custom x264 Parameter" encode setting string?


Cheers all

LoRd_MuldeR
20th February 2012, 20:13
You can add any configuration on a menu item? Loading template (Custom Matrix)?they have overlooked it in their discussion with holygamer perhaps. Is it possible to install it?

What would that menu item be supposed to do? :confused:

You can already "load" templates easily. The template is loaded immediately when you select a template from the "Template" combobox.

Custom matrices are set via "--cqm" or "--cqmfile", which you can add to the custom parameters. So that is already covered by current template system.

I don't see much reason to add more support for custom matrices, as custom matrices are pretty much obsolete and 99% of all users don't need them.

VideoFanatic
20th February 2012, 20:15
LoRd_MuldeR. You said this about having mkv as the default option:

You also have to be aware that 99% of all users believe that if a file does not play immediately on double-click in Windows Explorer, then that file is "broken" and the application who created the file is to blame! Thus by making MKV the default output format, I can save about ten angry e-mails per day.

I just dragged an MPEG2 into your program and saved it as mkv. The file doesn't play when I double-click on it (it doens't seem to be associated with any program) so what were you talking about? Also I played it in VLC Media Player but it had no sound.

LoRd_MuldeR
20th February 2012, 20:29
LoRd_MuldeR. You said this about having mkv as the default option:

You also have to be aware that 99% of all users believe that if a file does not play immediately on double-click in Windows Explorer, then that file is "broken" and the application who created the file is to blame! Thus by making MKV the default output format, I can save about ten angry e-mails per day.

I just dragged an MPEG2 into your program and saved it as mkv. The file doesn't play when I double-click on it (it doens't seem to be associated with any program) so what were you talking about?

This is different on any computer, of course :rolleyes:

However the chance that the user has installed some playback software, which can playback H.264 streams stored in a Matroska container and which has registered itself as default program for .MKV files, is pretty high!

VLC Player, for example, does do this by default:
http://img31.imageshack.us/img31/9028/clipboard53.th.png (http://img31.imageshack.us/img31/9028/clipboard53.png)

At the same time the chance that the user has installed some software which can open and play "raw" H.264 streams is rather low...

Also I played it in VLC Media Player but it had no sound.

Please read the section about audio encoding:
https://github.com/lordmulder/Simple-x264-Launcher/blob/master/ReadMe.txt#L168

nibus
22nd February 2012, 03:55
Hi Mulder, I had a few more feature suggestions -

1) Set (or have an option to) the default save directory to the same directory as the .avs source.
2) Refer to the last saved file type (mp4/mkv) when saving a new video.
3) Compute a file size estimate on CRF encodes (similar to MeGUI).

Once again thanks for the awesome gui.

kypec
22nd February 2012, 13:06
3) Compute a file size estimate on CRF encodes (similar to MeGUI).
:eek: Filesize can't be predicted when using CRF encoding mode so what are you talking about?

nibus
22nd February 2012, 13:53
:eek: Filesize can't be predicted when using CRF encoding mode so what are you talking about?

A rough estimate can be predicted, MeGUI does it and the longer the encode goes the more accurate the prediction is. I assume it averages out the bitrate of the encode from the beginning to the current position and multiplies that to the remaining frames.

reff24
22nd February 2012, 17:31
what's new in the versione from 21.02?

LoRd_MuldeR
22nd February 2012, 23:44
1) Set (or have an option to) the default save directory to the same directory as the .avs source.

The program already remembers the last "open from" and "save to" directory. Output file paths are generated for the current (last used) "save to" directory.

2) Refer to the last saved file type (mp4/mkv) when saving a new video.

This should be working too. Actually it did not always work as expected, due to a bug. Should be fixed with the next build.

3) Compute a file size estimate on CRF encodes (similar to MeGUI).

As kypec said, this could only be done as an "educated guess". Also I don't want to encourage people to use rate-control modes in ways they are not intended to be used. If you use CRF mode with a certain CRF value, then you should be doing so, because that CRF values retains the desired level of quality. But not because that CRF value coincidentally happens to hit the desired target file size for one particular source. We have 2-Pass mode to hit a specific file size...

what's new in the versione from 21.02?

Handling of multiple instances.

nibus
23rd February 2012, 01:43
The program already remembers the last "open from" and "save to" directory. Output file paths are generated for the current (last used) "save to" directory.

Right - what I meant was, automatically changing (or having an option to change) the save directory to the same directory as the AVS script being encoded, rather than the previously selected directory. So each script will have it's respective encode in the same directory.



This should be working too. Actually it did not always work as expected, due to a bug. Should be fixed with the next build.


:thanks:


As kypec said, this could only be done as an "educated guess". Also I don't want to encourage people to use rate-control modes in ways they are not intended to be used. If you use CRF mode with a certain CRF value, then you should be doing so, because that CRF values retains the desired level of quality. But not because that CRF value coincidentally happens to hit the desired target file size for one particular source. We have 2-Pass mode to hit a specific file size...

I don't encode for file size, but it is nice to see a rough estimate of a project. Some sources are simply too grainy to re-encode, so half way through the project it's nice to see if by chance the estimated file size is larger than the source. :eek:

LoRd_MuldeR
23rd February 2012, 01:54
I don't encode for file size, but it is nice to see a rough estimate of a project. Some sources are simply too grainy to re-encode, so half way through the project it's nice to see if by chance the estimated file size is larger than the source. :eek:

So you want a "live" estimate of the final size during the encode, based on "what has been encoded so far" ?

Well, that might be possible to do...

LoRd_MuldeR
23rd February 2012, 03:22
Nibus, please try with this TEST build.

nibus
23rd February 2012, 05:02
Nibus, please try with this TEST build.

Works perfectly! Exactly what I was requesting.

I'll run some longer encodes through it tonight and see how it does, but from some shorter tests it seems to be quite accurate.

kypec
23rd February 2012, 07:32
Right - what I meant was, automatically changing (or having an option to change) the save directory to the same directory as the AVS script being encoded, rather than the previously selected directory. So each script will have it's respective encode in the same directory.
I didn't try myself any of the latest versions (2.x) of Simple Launcher but the last branch behaves exactly like you want it to - you just need to drag&drop AVS file onto it instead of manual browse/open button.

nibus
23rd February 2012, 07:39
I didn't try myself any of the latest versions (2.x) of Simple Launcher but the last branch behaves exactly like you want it to - you just need to drag&drop AVS file onto it instead of manual browse/open button.

Ahh ok, I'd never tried drag and drop. Thanks.

MajorX
23rd February 2012, 09:25
need help when i try to encode with avs script the fps changes.
here my avs script,
FFVideoSource("F:\Video012.mkv")
Undot()

Input Video Frame rate: 29.970 fps
Output Frame rate: 24.326 fps

Help?

LoRd_MuldeR
23rd February 2012, 13:37
need help when i try to encode with avs script the fps changes.
here my avs script,

Input Video Frame rate: 29.970 fps
Output Frame rate: 24.326 fps

Help?

If you want your AVS script to output 29.97 fps, but it doesn't, simply append "AssumeFPS(30000, 1001) to your script.

I'll run some longer encodes through it tonight and see how it does, but from some shorter tests it seems to be quite accurate.

It's as "accurate" as it can be. It's only a very rough estimate. And fluctuations are to be expected, especially at the beginning...

(Though if the "complexity" of the source varies a lot, big fluctuations may even happen towards the end)

SeeMoreDigital
23rd February 2012, 19:49
If I input a video source which has a resolution of 1024x576 pixels. What "Custom x264 Parameter" string do I need to enter to resize the output to 720x576?


Cheers

LoRd_MuldeR
23rd February 2012, 20:27
If I input a video source which has a resolution of 1024x576 pixels. What "Custom x264 Parameter" string do I need to enter to resize the output to 720x576?

http://mewiki.project357.com/wiki/X264_Settings#resize

SeeMoreDigital
23rd February 2012, 22:36
http://mewiki.project357.com/wiki/X264_Settings#resize

I think I must be missing something. I placed the following code in the "Custom x264 Parameter" box: --resize:width=720,height=432,method=lanczos --sar 64:45

But all I got was: Process Exited with Error Code: -1

LoRd_MuldeR
23rd February 2012, 23:08
Seems like you didn' read properly ;)

--video-filter <filter1>/<filter2>
You can 'chain' as many filter operations as you like together.
The available filters are:

[...]resize:[width,height][,sar][,fittobox][,csp][,method]

nibus
24th February 2012, 03:12
It's as "accurate" as it can be. It's only a very rough estimate. And fluctuations are to be expected, especially at the beginning...

(Though if the "complexity" of the source varies a lot, big fluctuations may even happen towards the end)

Done a couple 6+ hour encodes and haven't run into any issues. Thanks again for the feature implementation. :thanks:

darkio
27th February 2012, 00:43
works very well with aviutl fake avi too (vfapi codec). I prefer edit in aviutl instead avisynth, and then encode with simple 264 gui.
I think more x264 cli option (like vfw version) are welcome for future :)
However, thanks a lot !

LoRd_MuldeR
27th February 2012, 01:05
I think more x264 cli option (like vfw version) are welcome for future :)


You can enter any CLI option that you like into the "custom parameters" edit box - except for those that are reserved for the GUI.
https://gitorious.org/simple-x264-launcher/simple-x264-launcher/blobs/9a7ddf16c422ec23c8451d1313ddf7d9484e271a/ReadMe.txt#line123

darkio
27th February 2012, 13:39
I've a little question for you about gui. I've very old version x264 cli specified and compiled to use with firecoder blu card (toshiba's spursengine). it use some external libs to for hardware. The sdk are free but I'm not competent to recompile it with new x264 to use with simplegui. check version and then stop to work because is old. There is a ffmpeg encoder for spurs engine into sdk. I've read license, I know ask support for old version, but i wish to ask you if possible.

LoRd_MuldeR
27th February 2012, 14:16
I've a little question for you about gui. I've very old version x264 cli specified and compiled to use with firecoder blu card (toshiba's spursengine). it use some external libs to for hardware. The sdk are free but I'm not competent to recompile it with new x264 to use with simplegui. check version and then stop to work because is old. There is a ffmpeg encoder for spurs engine into sdk. I've read license, I know ask support for old version, but i wish to ask you if possible.

Please read here:
https://gitorious.org/simple-x264-launcher/simple-x264-launcher/blobs/9a7ddf16c422ec23c8451d1313ddf7d9484e271a/ReadMe.txt#line88

icon
27th February 2012, 18:22
I didn't try myself any of the latest versions (2.x) of Simple Launcher but the last branch behaves exactly like you want it to - you just need to drag&drop AVS file onto it instead of manual browse/open button.

This doesn't work for me with either the last stable or the experimental build. It still defaulted to the last save location.

I also tried to remove the settings files that are saved, but that didn't work either. I do agree though, that having the save location defaulting to the avs source location is a good idea.

LoRd_MuldeR
27th February 2012, 19:14
The program will remember the last directory where you saved a file.

If you open another input file later (e.g. via Drag&Drop), the default output file name will be generated in the last "save to" directory.

Thus it will not necessarily generate the default output name in the same folder where the source file is located, but of course this is still may happen.

(And I don't like to change the current behavior, because I usually keep my source files and my output files in different directories)

icon
27th February 2012, 19:20
Thanks for the explanation.

Another thought, any way to tweak the stats of the encode after resuming from pausing? It appears that the stats don't get reset based upon when the encode resumes, but are based upon when the initial encoding started, therefore given fps and etas that are not reliable. Unlike many I suppose, I use the pause and resume function a lot. Thanks for sharing such a great program.

LoRd_MuldeR
27th February 2012, 19:26
Another thought, any way to tweak the stats of the encode after resuming from pausing? It appears that the stats don't get reset based upon when the encode resumes, but are based upon when the initial encoding started, therefore given fps and etas that are not reliable. Unlike many I suppose, I use the pause and resume function a lot. Thanks for sharing such a great program.

The FPS and ETA values are calculated by x264. The GUI program just displays what x264 outputs to STDOUT. So you will have to ask the x264 devs about this ;)

(Though I think this issue was discussed before)

SeeMoreDigital
27th February 2012, 19:30
I know it might be a bit of a cheek... But is there any chance you could add some more encoding options to the "Add Job" GUI?

Perhaps something like this: -

http://img813.imageshack.us/img813/7989/guiproposal.png


Cheers

LoRd_MuldeR
27th February 2012, 19:41
It's impossible to add a GUI option for each CLI parameter that x264 supports, unless you want to create a bloated mess.

Adding only the "most important" ones also impossible, because every user has his/her own optionon on which options should be on the GUI and which not.

Consequently I want to keep the GUI as simple as possible and leave everything else for the "Custom Parameters" box ;)

SeeMoreDigital
27th February 2012, 19:45
That's a shame...

darkio
27th February 2012, 20:31
I know it might be a bit of a cheek... But is there any chance you could add some more encoding options to the "Add Job" GUI?

Perhaps something like this: -

http://img813.imageshack.us/img813/7989/guiproposal.png


Cheers

Can be a good idea very basic encoding options, but if you wan't use avisynth, I suggest (like me) to edit your clip/movie in aviutl with your personal settings like output resolution or resize, framerate, sharpness, crop, denoise, deinterlace or IVTC and many other settings, then save project to frame serve via vfapi codec into mulder's gui. Aviutl is like virtualdub with external plugin's system. You can set colorimetry too. Very usefull. VFAPIConv.exe must be used to convert aviutl project (.aup) into uncompressed fake avi.

darkio
28th February 2012, 00:25
possible save and load queues and up/down jobs in the future ? I can't see version history...

LoRd_MuldeR
28th February 2012, 00:45
possible save and load queues and up/down jobs in the future ?

If at all, we could only save jobs that are in the "enqueued" state. But I don't see much use for it.

The relevant properties of a job object would be the input/output paths and the encoder settings. But the encoder settings are already covered by the "template" system.

So instead of loading a job, you can simply "load" (re-add) the same source file again and choose the suitable template.

I can't see version history...

I do not really maintain a version history :o

But you can look at the Git repository commit log, if you like:
https://gitorious.org/simple-x264-launcher/simple-x264-launcher/commits/master

Abyssal
7th March 2012, 05:18
I would also like to see more basic stuff added to the Add Job GUI like resizing and stuff like that, just like SeeMoreDigital posted. Only adding a few things doesn't equal a bloated mess.

Anyway, is there any chance for 10bit x264 support? I tried replacing the 8bit x264 that's in the tools folder but got errors that made the program close itself.

Either way, been trying your program a few times and I think it's pretty good - looking forward to future updates. :-)

Marin85
7th March 2012, 20:40
@LoRd_MuldeR: Awesome little tool you have written there! I very much like it for keeping the interface so clean! IMHO, it is soo much cooler than MeGUI and much more responsive.

I hope you would not mind me making a few little suggestions:

S1) Bundle the 10-bit x264 in your application with a switch for 8-bit and 10-bit mode :p

S2) An option to apply a given encoding profile to all jobs automatically, i.e. without having to confirm with "yes" for every job (for instance useful when encoding anime or tv show series where using same encoding profile seems reasonable idea).

S3) An ability to multi-select jobs from the list and/or to clear all jobs. Plus it would be nice to be able to remove a job via "Del" or some other keyboard shortcut.

S4) An option to set the process priority for x264.

I also have two questions:

Q1) Would it be possible to include an auto-update function for the latest builds of x264?

Q2) How safe is the pause function? In other words, is there any danger of introducing glitches in the H.264 stream by pausing and then resuming the job?


Now, regarding adding additional GUI elements for the various x264 settings, here is my opinion for what it's worth: given that most of the x264 parameters have been well-established for some time now, I think the options worth tweaking can be reduced to a small number. Whoever wants to tweak what's not supposed to be tweaked can be assumed to have deeper knowledge in x264 settings and hence be familiar with the command line :rolleyes: People will finally stop f*cking with the i-p and p-b ratios :p Here is my suggestion to what could be added to the GUI:
- Levels, partitions and decimate;
- me range, me algorithm, subme;
- MV prediction and Trellis;
- psy-rd;
- qcomp and AQ;
- b-frames, b-adapt and b-pyramid;
- scenecut, ref frames, weight-p
- deblock

On the other hand, when I think about it, these are still quite many additional options and will probably overbloat the clean GUI. Plus, people tend to overlook "hidden" options when they see lots of GUI options, thinking that is all they need, but there are exceptions, of course. So, it might turn confusing for some.

Well, anyways, thanks again for the great utility!

PS: I have been lately thinkering something like this myself, but your utility is so much prettier. It just made my day as I discovered it tonight quite by accident. :o

darkio
7th March 2012, 22:06
Replace button for saving template configuration (boring typing every time for a single change) and full quote Marin85 for S1, S2S3 and S4 suggestion steps. Internal ARS calculator like this (http://forum.doom9.org/showthread.php?t=107039) can be very very usefull usefull !
There are many peoples can't use avisynth script, so we ask you to help us with some very very basic settings, like resize, deinterlace or detelecine, output resolution, framerate and other small stuff.
This is great gui for x264, and can be improved :)

LoRd_MuldeR
7th March 2012, 22:23
I would also like to see more basic stuff added to the Add Job GUI like resizing and stuff like that, just like SeeMoreDigital posted. Only adding a few things doesn't equal a bloated mess.

Resizing is supported just fine. If you don't resize on the Avisynth side, you can use x264's resize filter with a simple custom command.

(It has been explain in this thread)

Anyway, is there any chance for 10bit x264 support? I tried replacing the 8bit x264 that's in the tools folder but got errors that made the program close itself.

10-Bit already is supported in the only way it can be supported: You will have to replace the 8-Bit x264 binary with a 10-Bit x264 binary.

If you get errors with the 10-Bit binary, then please give me detailed instructions on how to reproduce the issue...

LoRd_MuldeR
7th March 2012, 22:36
S1) Bundle the 10-bit x264 in your application with a switch for 8-bit and 10-bit mode :p

I won't include 10-Bit builds in the distribution package, because it would make the package even bigger.

Also most people don't need 10-Bit, because h/w support for 10-Bit does not exist and it doesn't seem like the situation will change anytime soon.

The people who need 10-Bit encoding can simply replace the 8-Bit binaries with 10-Bit binaries. Should be straight forward...

(I consider 10-Bit H.264 a "niche" product, really!)

S2) An option to apply a given encoding profile to all jobs automatically, i.e. without having to confirm with "yes" for every job (for instance useful when encoding anime or tv show series where using same encoding profile seems reasonable idea).

I may think of a way to do that.

S3) An ability to multi-select jobs from the list and/or to clear all jobs. Plus it would be nice to be able to remove a job via "Del" or some other keyboard shortcut.

Selecting more than one job at a time is not possible, because the details will be shown for the currently selected job. What to show if multiple jobs are selected?

Adding some keyboard shortcuts may be possible though.

S4) An option to set the process priority for x264.

What's wrong with "below normal" priority?

Would it be possible to include an auto-update function for the latest builds of x264?

Sure. But somebody has to code it. And somebody would have to provide and maintain the update server.

I have no plans to do that at the moment...

How safe is the pause function? In other words, is there any danger of introducing glitches in the H.264 stream by pausing and then resuming the job?

As safe as it can be.

Pause will suspend the main thread in the x264 process. Unpause will resume that thread.

If that triggered a deadlock (or other unexpected behavior) in x264, the responsible "race condition" would have to be fixed in x264...

(Note: I have not encountered any problems so far)

- Levels, partitions and decimate;
- me range, me algorithm, subme;
- MV prediction and Trellis;
- psy-rd;
- qcomp and AQ;
- b-frames, b-adapt and b-pyramid;
- scenecut, ref frames, weight-p
- deblock

These all are covered by the x264 Preset/Tuning system, so 99.9% of all users should never have to mess with these settings manually!

The few users who really have a good reason to overwrite any of these settings, can add the required option to the custom parameters easily...

(If a user doesn't know how to deal with CLI parameters, that is a clear indication the user should stick with the Preset/Tuning system ^^)

kypec
8th March 2012, 07:49
I won't include 10-Bit builds in the distribution package, because it would make the package even bigger.

The people who need 10-Bit encoding can simply replace the 8-Bit binaries with 10-Bit binaries. Should be straight forward...

@Marin85: here's my suggestion for you

Create 2 individual folders e.g. Launcher8b & Launcher10b.
Copy Launcher.exe and other required executables in both folders - these are small enough.
Keep 8-bit x264 executables in the first folder, 10-bit x264 executables in the other.
Put shortcuts to each of your launcher.exe on your desktop or wherever else you need them.
Launch the appropriate launcher as desired ;)

LoRd_MuldeR
8th March 2012, 09:34
@Marin85: here's my suggestion for you

Create 2 individual folders e.g. Launcher8b & Launcher10b.
Copy Launcher.exe and other required executables in both folders - these are small enough.
Keep 8-bit x264 executables in the first folder, 10-bit x264 executables in the other.
Put shortcuts to each of your launcher.exe on your desktop or wherever else you need them.
Launch the appropriate launcher as desired ;)


This sounds like a feasible solution, if you really need to switch between 8-Bit and 10-Bit frequently.

Though be aware that you won't be able to launch two instances (e.g. the "8-Bit copy" and the "10-Bit copy") at the same time.