summaryrefslogtreecommitdiffstats
path: root/libhb/work.c
Commit message (Collapse)AuthorAgeFilesLines
* Formatting: Remove a lot of trailing whitespace.saintdev2008-02-211-45/+45
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1307 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Sanity check the input codec is AC3 when selecting AC3 pass through to avoid ↵eddyg2008-02-181-0/+9
| | | | | | crash when it is mpega or lpcm etc. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1290 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Only show a line in the log for filters if there are any, only show a line ↵jbrjake2008-02-161-2/+2
| | | | | | for dynamic range compression if it's enabled. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1274 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Adds another safeguard to ensure AC3 pass-thru uses a 48khz sample rate.jbrjake2008-02-161-0/+7
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1270 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Allow mac gui to select AC-3 + AAC at the same time, still needs CLI work ↵eddyg2008-02-161-4/+22
| | | | | | for the same. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1267 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Always use a sample rate of 48000hz for AC3.jbrjake2008-02-141-0/+3
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1265 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Variable frame rate improvements.jbrjake2008-02-041-9/+15
| | | | | | | | | - Makes it work better with the source's time stamps and avoids discontinuities, by removing its lazy assumption that all frames are 3003 ticks long. - Handles more than 1 frame being dropped out of 5. - Preserves chapter markers from being dropped along with frames they're attached to (thanks van!). - Also, since VFR no longer requires input at 29.97 fps, removes the hard-coding of that frame rate. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1249 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Maintains separate filter settings for each job. This prevents the MacGui ↵jbrjake2008-01-221-1/+23
| | | | | | from using the same filter settings for every job in the queue. Patch from travistex. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1228 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Don't bother informing the user when grayscale is off, since that's the case ↵jbrjake2008-01-141-1/+3
| | | | | | 99% of the time anyway. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1193 b64f7644-9d1e-0410-96f1-a4d463321fa5
* fix for duplicate chapters when encoding with ffmpeg.van2008-01-061-3/+7
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1169 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Extends hb_set_anamorphic_size() to make it possible to do "dry-runs"...this ↵jbrjake2007-12-281-1/+1
| | | | | | way the MacGui can calculate loose anamorphic values for displaying preview images, before the job variables are directly set in work.c. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1153 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Adds extra, user-selectable dynamic range compression to the liba52 ↵jbrjake2007-12-081-0/+3
| | | | | | | | interface, making softer sounds louder. Based on code from liba52's A52Decoder, used in Perian's preferences pane. Set with a job->dynamic_range_compression float, with valid values being 1.0 - 4.0. Controlled from the CLI with --dynamic-range-compression or -D. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1108 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Moves the readout of applied x264 options from test.c to work.c, so the ↵jbrjake2007-11-161-0/+2
| | | | | | MacGui can see it. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1064 b64f7644-9d1e-0410-96f1-a4d463321fa5
* First attempt at variable frame rate detelecining for NTSC video sources.jbrjake2007-11-101-0/+21
| | | | | | | This check-in includes the library code as well as the CLI implementation. Only works with MP4 and MKV, untested with high profile, results may vary with mixed content, consult a physician if condition persists for longer than four hours. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1051 b64f7644-9d1e-0410-96f1-a4d463321fa5
* "Loose" anamorphic:jbrjake2007-10-161-3/+13
| | | | | | | | - Scales the storage frame size to arbitrary widths, like 640 for the iPod. - Uses dimensions that divide cleanly by an arbitrary number (default: 16) and adjusts the SAR to match - Uses ITU PAR values when the video is meant to be overscanned ( 7+ pixels cropped on left+right) git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1029 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Change the fifo size from being statically tuned for a Mac Pro with 4 CPUs ↵eddyg2007-10-131-10/+10
| | | | | | to dynamically adjust according to how many processors are available. 8 extra buffers in the fifo per CPU available. Hopefully this will make the single CPU systems run at pretty much the same speed as before (although they may still be slower if they are low on memory and start thrashing the pager). git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1023 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Don't drop subtitles when crossing PTS discontinuities by using buffer ↵eddyg2007-10-081-2/+5
| | | | | | sequence numbers to determine where in the stream the buffer came from. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1011 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Two changes, one ensure zero size buffers are zero size, second change the ↵eddyg2007-10-041-2/+2
| | | | | | buffer cleanup to be later. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@999 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Re-enable 6ch vorbis audio.saintdev2007-09-161-2/+2
| | | | | | | Vorbis won't allow bitrates < 168kbps with 6ch audio, so anything less is reset to 168kbps. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@966 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Reverts an errant checking for from rev 960dynaflash2007-09-131-70/+0
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@961 b64f7644-9d1e-0410-96f1-a4d463321fa5
* jbrjake's loose pixel ratio patch.saintdev2007-09-131-0/+70
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@960 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Added buffer management and changed fifo sizes. Changed job->subtitle_scan ↵eddyg2007-09-111-16/+21
| | | | | | to job->indepth_scan, and fixed memory init bug in denoise.c. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@945 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Die, non-standard printf logging, die!jbrjake2007-08-291-1/+1
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@895 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Add Subtitle scanning for forced subtitles and normal subtitles from the CLIeddyg2007-08-211-14/+69
| | | | | | | and the MacOS GUI. See the new subtitle language options in the GUI. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@844 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Prettier logging display for filters.jbrjake2007-08-141-4/+4
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@814 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Moves the filters' logging info to work.c, adds parameter info. I also ↵jbrjake2007-08-141-1/+14
| | | | | | changed the deinterlace filter name to include its default method (ffmpeg) and removed the logging line from work.c that said if job->deinterlace was true or not, as it's now superfluous. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@812 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Native language subtitle scan improvements. Thanks, eddyg!jbrjake2007-07-261-41/+48
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@741 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Fixes to the CLI for forced subtitles, and Turbo.saintdev2007-07-061-2/+3
| | | | | | | | | -Fixes a bug in the HB CLI whereby you can't use the native-language switch to enable subtitles when doing single pass. -Changes the threshold for enabling subtitles automatically during a subtitle scan from 20% to 10%. -Changes the turbo options to match what the GUI is doing. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@650 b64f7644-9d1e-0410-96f1-a4d463321fa5
* A big batch of patches from eddyg.jbrjake2007-06-061-12/+107
| | | | | | | | | | | | | Adds following options to the CLI: --subtitle-scan for auto-selecting subtitles for foreign language segments in native language audio tracks --native-language for auto-selecting subtitles for foreign language audio without knowing the track number --longest for auto-selecting the longest title like in the MacGui --turbo for improving speed on the first pass of a two pass encode with x264 (based on superdump's turbo x264 options in mencoder). Thanks, eddyg! git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@600 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Updated the input channel layouts to store the source LFE information as ↵maurj2007-05-061-11/+12
| | | | | | | | | well as the non-LFE layout. This is so muxavi.c can output the correct channel count for AC3 passthru for all AC3 sources. Updated Controller.mm, scan.c and work.c to use these revised layouts. Added a new property to the work object, to remember the source audio codec for audio work objects. This enables encfaac to detect an 6-channel AC3 source to apply the QuickTime 6-channel audio mapping (as opposed to a DTS source, which doesn't need it). Fixed the Dolby Pro Logic I/II downmix mappings in libdca and updated the libdca patch. Uploaded a new set of pre-built darwin contribs (0014) with this patch applied. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@570 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Updated do_job() in work.c to remove any non-AC3 audio tracks from the job ↵maurj2007-05-041-0/+14
| | | | | | before performing AC3 passthru. This prevents Bad Things from happening when a DTS, MPEG2 or LPCM audio track is selected and AC3 passthru to AVI is selected. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@569 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Enabled DTS channel mixdowns by moving to a more generic input channel ↵maurj2007-05-041-214/+95
| | | | | | layout set of constants. Updated Controller.mm to use these generic input layout constants when deciding which mixdowns to offer. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@565 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Added support for DTS audio. DTS audio streams (of 5.1 audio and below) ↵maurj2007-05-021-8/+123
| | | | | | | | | will be detected and decoded. This requires a new library - libdca (and patch) - which is included (in patched form) in a new version of the pre-built UB Darwin contribs (0012). These have been uploaded to download.m0k.org/handbrake/contrib/ . I haven't yet added any code to Controller.mm to recognise the DTS streams as supporting mono / 6ch DPL1 / DPL2 downmixes. Note: running Jam on the new library required me to update some tools on Mac OS X - possibly libtool, autoconf, automake. Not sure which made the difference, but these were the ones I updated. it won't jam successfully without this. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@559 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Fix Previous Bad commit for Cyanders Chapter Markersdynaflash2007-04-251-0/+8
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@548 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Much better B-frame muxing frame-reordering. This will preserve the sps/pps ↵jbrjake2007-04-161-1/+1
| | | | | | | | info, properly offset the first frame, and flush any remaining frames at the end of the encode. Patch by: Nyx git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@513 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Added libhb and CLI support for Dolby Pro Logic II 5.0 matrix encoding. ↵maurj2007-04-111-43/+144
| | | | | | | | *NOT YET ADDED TO THE GUI*. Handbrake now uses a more general "audio mixdown" concept. For each audio track to be converted you specify a mixdown. These are defined in common.h. This checkin only allows you to specify one mixdown for all tracks in the CLI, although everything is in place internally to specify a different mixdown per track. In the CLI, the "-6 --surround" option has been repurposed as a "-6 --mixdown" option, with a string parameter of mono/stereo/dpl1/dpl2/6ch. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@494 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Amended work.c to remember the number of source A52 channels and lfe ↵maurj2007-04-021-0/+5
| | | | | | channels, so that deca52.c can correctly detect a 5.1 source which needs mixing down to Dolby Digital. Previously it was just mixing 5.1 down to stereo. This has been broken since rev 438, when the multi-soundtrack bug was fixed. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@472 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Fix about 156,199 bytes of leaked memory.saintdev2007-03-311-0/+5
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@469 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Amended the code comments about 6-channel and 1-channel audio extraction to ↵maurj2007-03-271-7/+6
| | | | | | reflect that it's no longer just for AAC, following saintdev's addition of 6-ch and 1-ch for OGM. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@458 b64f7644-9d1e-0410-96f1-a4d463321fa5
* -6 channel surround for Vorbis/OGM. The channel mapping seems right for VLC, ↵saintdev2007-03-271-3/+4
| | | | | | | | but may be messed up for other players. -Other small fixes. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@456 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Applied and committed saintdev's patch to fix multi-track audio. Only in ↵maurj2007-03-211-19/+36
| | | | | | | | the CLI for now - the GUI will need updating to reinstate the second audio dropdown. If the -6 option is specified in the CLI (and faac is specified), then *any* 5.1 tracks specified will be exported as 6-channel AAC. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@438 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Merge the 5.1 branch into the trunk.prigaux2007-03-061-0/+419
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@422 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Merge the 0.8.0_mpeg4ip branch into the trunkprigaux2007-02-111-350/+0
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@285 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Revert changes to threading sleep intervals. johnallen2007-01-091-9/+5
| | | | | | | Some users have issues with this. It is less risky to not include this for release 0.7.2 git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@100 b64f7644-9d1e-0410-96f1-a4d463321fa5
* added worker thread sleep throttling.johnallen2007-01-081-5/+14
| | | | | | | | | | each of the work object threads now self adjust their sleep interval based on the "fullness" of their fifo. 80% is the choose threshold. Work objects with a fifo fullness of greater than 80% increase their sleep interval. This allows other work object with less than 80% fullness more CPU usage. Also adjusted thread_func, reader, and muxer sleep intervals to more reasonable values. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@98 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Documentation begins. johnallen2007-01-071-0/+29
| | | | | | | Added method documentation for hb.c as well as a few methods in sync.c and work.c More to come. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@97 b64f7644-9d1e-0410-96f1-a4d463321fa5
* RapidSVN commited changes to files I did not want commited. This commit ↵johnallen2007-01-061-15/+0
| | | | | | revert those files back to rev 92. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@94 b64f7644-9d1e-0410-96f1-a4d463321fa5
* added Doxyfile, config file for doxygenjohnallen2007-01-061-0/+15
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@93 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Merge from avformat branchtiter2006-04-171-1/+2
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@60 b64f7644-9d1e-0410-96f1-a4d463321fa5
* Simple threading change (~4% faster). Breaks pause/resume for nowtiter2006-03-181-137/+45
| | | | git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@40 b64f7644-9d1e-0410-96f1-a4d463321fa5