summaryrefslogtreecommitdiffstats
path: root/libhb
Commit message (Collapse)AuthorAgeFilesLines
* libhb: update hb_get_best_mixdown(). I was partially borken after revision 4754.Rodeo2012-06-191-57/+34
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4755 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: drop HB_INPUT_CH_LAYOUT_*Rodeo2012-06-1817-322/+238
| | | | | | | | AV_CH_LAYOUT_* works for us, and as its usage becomes more widespread in libhb, translating between the two formats gets increasingly tedious. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4754 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Remove debug code.Rodeo2012-06-181-2/+0
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4751 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Fix HE-AAC in MKV.Rodeo2012-06-181-1/+16
| | | | | | | | HandBrake's output should now play correctly on Sigma-based hardware players (among others). git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4750 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Add PGS codec ID to libmkv and use it.Rodeo2012-06-181-1/+1
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4749 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Fix Foreign Audio Search bug introduced in revision 4677.Rodeo2012-06-171-1/+11
| | | | | | | | interjob->select_subtitle was never freed, causing it to be added to all following queued encodes. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4748 b64f7644-9d1e-0410-96f1-a4d463321fa5
* remove unnecessary includejstebbins2012-06-171-1/+0
| | | | | | | Thanks for Rogerio Brito for patch git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4744 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Updated file copyright / GPL headerssr552012-06-1564-167/+425
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4737 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Portability patchesjstebbins2012-06-071-1/+1
| | | | | | | | | gudev is only available on linux, so ifdef it out on all other systems. also add some definitions to the make system for generic gnu and freebsd systems. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4717 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Make HB_AMIXDOWN_* defines a simple enumeration. The existing system wasn't ↵Rodeo2012-06-0613-94/+107
| | | | | | necessary and didn't work in all decoders for Dolby downmixing. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4714 b64f7644-9d1e-0410-96f1-a4d463321fa5
* decdca: attempt to fix Dolby Surround and Pro Logic II mixdown. We were ↵Rodeo2012-05-277-99/+139
| | | | | | | | | | | | | | doing it wrong in some cases. This means Dolby Pro Logic II is now only available for sources with at least L, R, C, Ls, Rs channels (as well as any additional channels), due to some libdca limitations. This will eventually go away when we use our own downmixing for all sources. Further cleanup to follow. Also cleans up usage of audio->config.in.flags (was audio->config.flags.*). git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4705 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Bump x264 to r2200-999b753.Rodeo2012-05-261-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - H.264 Level 5.2 support. - Threaded lookahead: improved encoding speed with very fast settings, on systems with 8 processor "threads" or more. 'By default, lookahead threads are 1/6 of regular threads. This isn't exacting, but it seems to work well for all presets on real systems. With sliced-threads, it's the same as the number of encoding threads.' Mini-benchmark: --------------- 2.2 GHz Intel Core i7, 8 processor threads (4 physical cores + 4 virtual cores), Mac OS X 10.7.4. HandBrake's "Normal" preset. libavcodec decoding threads: 8 / 2 + 1 = 5 x264 encoding threads: 8 * 3 / 2 = 12 x264 lookahead threads: 12 / 6 = 2 Blu-ray, H.264, 1920x1080 -> 1920x800 ~48 fps with threaded lookahead, ~42 fps without DVD, MPEG-2, 720x576 -> 720x576 ~224 fps with threaded lookahead, ~192 fps without git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4704 b64f7644-9d1e-0410-96f1-a4d463321fa5
* fix more compiler warningsjstebbins2012-05-263-8/+3
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4702 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Fix crash in MKV muxer with SRT subtitle sources (introduced in revision 4605).Rodeo2012-05-201-0/+5
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4692 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Forgot to svn add some taskset filesjstebbins2012-05-183-0/+370
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4686 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: tasksets API provided by scsiguyjstebbins2012-05-175-448/+188
| | | | | | | | | | This is an easier to use API for launching multithreaded tasks. And it is more portable since it does not rely on undefined/implementation specific behavior of POSIX mutexes. That is, the ability for one thread to unlock a mutex owned by another thread. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4685 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: forgot to clear the flag indicating forced sub seenjstebbins2012-05-171-0/+1
| | | | | | | | since the flag wasn't cleared, it would output multiple empty subs for each forced sub git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4684 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: improve termination of forced subtitlesjstebbins2012-05-171-5/+107
| | | | | | | | | There isn't always an "empty" sub directly after a forced subtitle. This causes the forced subtitle to be displayed for too long. So take the next sub and convert it to an empty sub. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4683 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Foreign Audio Search: improve duplicate subtitle detection.Rodeo2012-05-141-6/+8
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4679 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Fix a couple Foreign Audio Search issues causes by the changes introduced in ↵Rodeo2012-05-141-9/+3
| | | | | | | | | | | | revision 4622: - hang if forced-only were not set - Foreign Audio Search would select a subtitle track containing forced subtitles even if forced-only were not set git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4678 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: include subtitles in all passes. When doing 2-pass, we want to send ↵Rodeo2012-05-142-51/+25
| | | | | | | | | | the same input to the video encoder in both passes, which requires including subtitles in case one has to be burned-in. Update Foreign Audio Search to work with the new behavior. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4677 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Fix a crash when doing Foreign Audio Search with subtitle tracks that ↵Rodeo2012-05-141-31/+18
| | | | | | | | | | contain extradata (e.g. demuxed via libavformat). Fix by John Stebbins. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4675 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Sorry, missed one.Rodeo2012-05-121-2/+3
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4663 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Further cleanup.Rodeo2012-05-121-10/+10
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4662 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Cleanup: merge two consecutive if( job->indepth_scan ) blocks.Rodeo2012-05-121-18/+8
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4661 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: PGS subtitle improvements.Rodeo2012-05-102-21/+98
| | | | | | | | | | | | | | Some devices (such as the WD TV Live) expect PGS subtitle "frames" to come as a single packet, whereas on Blu-ray, each frame "segment" comes in its own packet. When doing PGS passthrough, merge packets so that 1 subtitle == 1 packet. This matches what MakeMKV amd mkvmerge do. Also, when doing forced-only extraction, don't include more 'empty' PGS subtitles than necessary. In muxmkv, cleanup negative subtitle durations (doesn't appear to fix anything, but it doesn't make anything worse either). git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4658 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: don't relocate SSA subtitle when burningjstebbins2012-05-101-55/+63
| | | | | | | | | | Unlike dvd or bd subs which may be in the crop zone of the video, the ssa renderer knows the actual video dimensions and adjusts position for us. Moving them when they are "close" to the borders just makes a complete hash of things, so lets not do that. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4657 b64f7644-9d1e-0410-96f1-a4d463321fa5
* decavcodec: merge double if to a single statement.Rodeo2012-05-091-6/+3
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4656 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: fix another filter initialization problemjstebbins2012-05-071-1/+3
| | | | | | | if a filter fails to initialize, the next filter in the list got skipped git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4650 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: yet another fix for ssa burn-in positioning problemjstebbins2012-05-051-8/+4
| | | | | | | | | We must offset the position that libass gives us by the top and left cropping since the frame size we are telling libass to render into has the cropping removed. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4643 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: Fix problem with positions of burned-in subsjstebbins2012-05-0511-75/+16
| | | | | | | | | | | | | | | | | When cropping and/or scaling, the position of burned-in SSA subs was broken. Also, when scaling, the position of all other burned-in subs was broken. Part of this fix is to revert a bit of filter initialization changes that were made in this commit https://trac.handbrake.fr/changeset/4605 The other part of the fix is to add cropping parameters to the initialization of the subtitle rendering filter. This filter needs the *original* title dimensions and the crop values in order to compute the positions properly. The changes that I am reverting gave it the scaled job dimensions and the crop values. This was wrong in so many ways it's embarassing :p git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4642 b64f7644-9d1e-0410-96f1-a4d463321fa5
* audio->config.lang.description: code cleanup.Rodeo2012-05-034-180/+199
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4637 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: if no source chapter name information is available, set default ↵Rodeo2012-05-035-37/+67
| | | | | | | | | | | | | | chapters names explicitly (rather than leaving it to the interfaces). Standardize calculation of chapter->hours, chapter->minutes and chapter->seconds across all sources. Get rid of an unused variable in libhb/dvd.c Ignore chapter names set by MakeMKV. "Chapter 1" is just as good as, if not better than "Chapter 01" or even "Chapter 00". git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4636 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Scan: fix some 24000/1001 sources being detected as "almost" 24000/1001, ↵Rodeo2012-05-021-1/+12
| | | | | | using is_close_to(). git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4631 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: fix initialization problem in chroma resamplingjstebbins2012-05-021-0/+1
| | | | | | | may account for https://forum.handbrake.fr/viewtopic.php?f=12&t=24168 git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4630 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: fix problem with filter initializationjstebbins2012-05-021-0/+1
| | | | | | | Under certain circumstances, a filter could get skipped during initialization git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4628 b64f7644-9d1e-0410-96f1-a4d463321fa5
* don't do combing check twice per frame when bobbingjstebbins2012-05-011-1/+13
| | | | | | | and fix saving bob setting in LinGui presets git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4626 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: bob deinterlacingjstebbins2012-05-012-148/+229
| | | | | | | | This is jbrjake's patch for bob deinterlacing applied to decomb and deinterlace filters. Thanks to yeasah's for refinements and testing of this patch. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4625 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Minor simplification.Rodeo2012-05-011-2/+2
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4623 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Simplify Foreign Audio Search code:Rodeo2012-05-014-102/+98
| | | | | | | | | | | | | | | | | | | | - move all subtitle hit counting to the decoders instead of reader ---> allows us to count actual subtitles rather than just packets - always count subtitles, even when not doing a scan (may be useful in the future) Miscellaneous improvements: - always insert select_subtitle at the head of the output subtitle list, to make it less likely to be dropped - when multiple subtitle tracks have forced hits, pick the track with the fewest forced hits ---> Foreign Audio Search should now work with Star Wars on Blu-ray - logging improvements (more readable, and log job->select_subtitle configuration - Forced Only vs. All, Render vs. Passthrough) git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4622 b64f7644-9d1e-0410-96f1-a4d463321fa5
* merge assorted fixes provided by Rogerio Britojstebbins2012-05-013-2/+7
| | | | | | | | Pretty much all resource cleanup issues on error condition handling. Thanks Rogerio! git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4620 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: fix problem with incorrect addition of audio silencejstebbins2012-05-016-3/+21
| | | | | | | | | | | | sync needs the precise duration of a frame of audio and has no way to compute it for passthru audio. So add a duration member to hb_buffer_t and set it in the audio decoders. This should eventually supersede hb_buffer_t member "stop" since it provides redundant information. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4618 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: allow arbitrary number of preview images, fixes potential crashjstebbins2012-05-011-9/+28
| | | | | | | | | scan.c had a limit of 30 previews due to fixed array size. But test.c didn't limit the max number of previews, so it was possible to generate a crash by specifying > 30. This removes the limitation. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4616 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Fix a potential null pointer referencejstebbins2012-04-281-1/+1
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4609 b64f7644-9d1e-0410-96f1-a4d463321fa5
* PGS (bluray) subtitle support \o/jstebbins2012-04-2629-156/+1001
| | | | | | | | | | | | Thanks to patches supplied by David Mitchell and Rob McMullen we finally have PGS support. I added a fix for libav pgs timestamp processing and detection of forced subtitles to their work, then made foreign audio search work with PGS subs. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4605 b64f7644-9d1e-0410-96f1-a4d463321fa5
* LinGui: allow the user to select and use a bitrate for audio autopassthrujstebbins2012-04-261-1/+4
| | | | | | | | If the fallback encoder is used, the user should be able to set the bitrate that is used. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4604 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: fix crash when subtitle render filter fails to initializejstebbins2012-04-152-5/+6
| | | | | | | | | | | This can happen for non-fatal reasons when doing foreign audio search. This makes all filter init failures non-fatal. We may want to introduce fatal errors at some point. I need to inspect all the filters and see if there are any errors that really must be fatal. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4600 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: fix problem with fps calculation in 2 pass encodesjstebbins2012-04-141-1/+1
| | | | | | | | | interjob was not getting initialized at the end of the 1st pass because for some unfathomable reason, I did not save the job in the filter objects private data even though I had a job variable there. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4599 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: fix estimated number of frames expectedjstebbins2012-04-111-2/+0
| | | | | | | | we don't need to overestimate it anymore since we do not terminate the encode when this value is reached. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4588 b64f7644-9d1e-0410-96f1-a4d463321fa5
* libhb: handle TS streams that have broken DTS timestampsjstebbins2012-04-111-0/+7
| | | | | | | | If the DTS is > PTS, ignore it because this can't happen in a properly constructed TS stream. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4586 b64f7644-9d1e-0410-96f1-a4d463321fa5