76 Commits

Author SHA1 Message Date
Richard Stanway
dfbc2f9b54 Fix incorrect buffer size 2014-08-13 02:06:09 +02:00
Richard Stanway
992f0601b5 Show HRESULT descriptions in error messages 2014-08-09 20:09:43 +02:00
Richard Stanway
12f90b0f8b Start sound playback in MMDeviceAudioSource::Reinitialize
Fixes issues where the desktop device would drop and reacquire then stop providing audio due to no audio being played, causing OBS to freeze and break horribly.
2014-07-22 23:15:30 +02:00
jp9000
e2ae54ffb3 Remove 'use inputs devices for desktop audio'
Caused us no end of pain.  Users clicked it so much that it made us all
snap.  Now, if a user really, REALLY wants to use it, they'll have to
manually set the ini file variable in their profile ini, under [Audio],
InputDevicesForDesktopSound=1
2014-04-11 21:40:27 -07:00
jp9000
7cca8663a2 Game capture: Add anti-cheat compatibility
- Add an option in game capture to use SetWindowsHookEx instead of
   CreateRemoteThread to inject the library.

 - Add logging of what process game capture is trying to capture.

 - Rename "audio time offset" where it was used to "audio sync offset"

 - Adde logging for audio sync offsets

 - Update version to 0.62b test 1
2014-04-09 00:10:33 -07:00
jp9000
f76e8bcaa4 Added a "Reinitialize" button for mics
If the mic device starts going crazy or needs to be reset for whatever
possible reason and you don't want to restart the stream, you can now
reset the mic by using the "Reinitialize" button in audio settings next
to the mic device drop-down.  This will shut down the mic, and then
reinitialize it one second later.

Shouldn't need to be used with the newer audio code, but is provided
just in case.
2014-01-10 20:13:02 -07:00
jp9000
75c6d10aa0 Added audio burst compensation (fix sync)
- Fixed an issue where audio data that came in bursts would cause
   desyncs.  Basically, if data came in too late, it would continue to
   buffer little by little, causing progressive desync with certain
   microphones and capture devices (avermedia stream engine for the live
   gamer portable especially).  Also seemed to happen with HDMI data
   from the newer game consoles, like xbox one apparently, though I
   can't be too sure.

   Now, it queries the mic and auxilary sound sources until sound
   buffers are depleted.  After doing so, it then "sorts" the audio
   packets timestamps backwards from the most recent packet to the
   oldest audio packet.  By doing this, it compensates for burst, and
   ensures that all audio data is seamless.  New burst data coming in
   will then line up properly with the older data via the sort function.

   NOTE: This needs testing
2014-01-05 16:58:54 -07:00
jp9000
1da78b984c Microphone devices now properly reacquire when lost
1.) Audio devices initialized with WASAPI (MMDeviceAudioSource) now
properly attempt to reacquire every 2 seconds after device has been
unplugged.

This particular issue really shouldn't have taken this long to have been
resolved, please make things like this a higher priority next time (I'm
looking at you Jim.  ..or, I'm looking at myself, rather)

To all users who have been afflicted by this issue for a long time, I
sincerely apologize.

2.) Made String::Compare and String::operator== and != use 'bool'
instead of BOOL for return values (this isn't the 90's anymore)
2014-01-03 07:04:13 -07:00
jp9000
49241dc400 Added ability to use input devices for desktop audio, added a 'point filtering' option to text output source 2013-12-05 17:22:24 -07:00
jp9000
6e82cb201c 0.583 - fixed a tiny bug for mic audio time offset, made a minor tweak to an audio coefficient, and added a new string 2013-10-24 08:00:43 -07:00
jp9000
6e8b6824a2 made a potential workaround for kraken headsets (bad drivers from razer that don't allow floats when capturing) 2013-09-11 01:45:10 -07:00
jp9000
7cbe273e81 one minor adjustment to audio function variable just to be safe 2013-09-08 23:50:33 -07:00
jp9000
39179c389f Made the mic sync fix thing optional 2013-08-16 17:55:11 -07:00
jp9000
ded23cdbea recommented some debug code 2013-08-10 01:47:29 -07:00
jp9000
b47dd4d979 Testing a fix for mic sampling issues that cause desync 2013-08-10 00:10:32 -07:00
HomeWorld
68a8ee95b8 Log dwm/bitrate changes at runtime 2013-07-27 17:58:12 +03:00
jp9000
8ddfeb8352 removed mic debug log messages 2013-07-26 15:31:41 -07:00
jp9000
120a2108b2 make audio sources log frequency/samples per sec 2013-07-23 05:58:00 -07:00
jp9000
2d05e4edd3 reverted to memcpy because Jim apparently didn't do proper testing like he should have 2013-05-03 17:17:45 -07:00
jp9000
eb960a5a2e increased threshold at which new audio samples can be discarded 2013-04-26 00:40:54 -07:00
jp9000
f01fc602ce made a hack for when mic data gets behind due to minor device sampling issues 2013-04-25 16:02:04 -07:00
jp9000
bd9e916985 added global audio offset back in 2013-04-19 08:41:49 -07:00
jp9000
139a1119fd apply timestamp smoothing to all devices to prevent stuttering/hiccupts 2013-04-18 09:06:15 -07:00
jp9000
78501dacc4 yet more (and hopefully final) audio subsystem fixes 2013-04-16 19:41:55 -07:00
jp9000
20711fa013 okay, more audio issues fixed. thank god. 2013-04-12 01:40:32 -07:00
jp9000
8d41d8f61e fixed a timing bug on devices that don't output the proper 10ms sample sizes 2013-04-12 00:10:20 -07:00
jp9000
eb676b5b6a 0.48.013 - Fixed a few more issues with the audio subsystem 2013-04-10 22:18:52 -07:00
jp9000
2d1bb2189c 0.48.012 - properly account for WASAPI timing on packets that are not exactly 10ms samples 2013-04-06 01:02:03 -07:00
jp9000
8d95a1e7ac Made a significant number of adjustments to the audio subsystem that should ensure all extra audio streams play back properly and on time 2013-04-05 16:56:02 -07:00
jp9000
333e148597 Got rid of the redundant clockFreq param for the QPC time functions 2013-04-02 23:04:26 -07:00
jp9000
07d2e2bdd8 Fixed a bug in advanced that always set the global audio time offset to 50ms when the advanced page was used. just disabled global audio time offset for the time being 2013-02-26 16:27:03 -07:00
jp9000
75c83e83bc Added an option to force mic to use the QPC timestamps (or alternatively use desktop time if disabled)
Fixed a potential minor issue with directshow devices choosing a less-than-optimal output format
2013-02-25 16:58:06 -07:00
jp9000
3be930e719 added compatibility mode for software capture
added triple buffering option to advanced settings (potentially as an optimization for some cards)
added scene buffering time option to advanced settings (mainly for sound devices)
moved "Use CBR" to encoding section, made buffer size automatically default to the same as bitrate unless "Use Custom Buffer Size" is checked
2013-02-24 07:51:01 -07:00
jp9000
672333fa6a Added volume bar to directshow source,
moved the volume controls to OBSApi,
made some minor tweaks to mic audio
2013-02-21 01:42:35 -07:00
jp9000
c78f7161a5 moved gamma stuff to software capture and game capture 2013-02-16 02:51:24 -07:00
jp9000
87fd5a155c Added C-style API exports instead of relying on horrible virtual function tables
Fixed a bug with item insertation
2013-02-06 09:39:15 -07:00
jp9000
66183e65d1 woops, minor stupid little code bit 2013-01-30 04:45:26 -07:00
jp9000
4a7dc0154c fixed some major issues with frame timing
fixed cfr sync issue
fixed some major sync issues that may have been present in major version
fixed a bug with audio output timing
made mic data output more accurately as long as the qpc timestamp checks out
2013-01-30 04:43:40 -07:00
jp9000
b76b863687 reverted some audio code to an older working version for now 2013-01-28 03:55:03 -07:00
jp9000
ab4daa4a6e added an option to change global audio time
made a slight adjustment to the way the webroot message works
2013-01-27 23:30:14 -07:00
jp9000
9dca975317 fixed potenital bug with devices where it could query a dumb videoinfo2 2013-01-26 23:20:41 -07:00
jp9000
e2ea43ca93 merging develepment branch. don't kill me! 2013-01-24 20:30:22 -07:00
Richard Stanway
11780d4d47 Don't crash on bad timestamps in debug build 2013-01-10 23:33:35 -05:00
jp9000
31a7fe5957 Fixed some bugs
Made is so you can adjust mic/device audio time while streaming
updated installer script
updated some locale
got rid of audio time calculation completely
2013-01-02 21:29:26 -07:00
jp9000
645f9c49ef added capture card audio fully
added mic/capture card audio time offset controls
fixed a memory leak with gifs
don't show fonts that GDI+ can't render
2013-01-02 01:14:30 -07:00
jp9000
ab859da2aa fixed some mic sync issues
fixed some potential desktop sync issues
fixed some bad names
fixed more json issues
fixed mp4 file syncing
2012-12-30 14:30:08 -07:00
jp9000
efe771565f capture card audio stuff, audio system adjustments, audio thread adjustments 2012-12-25 09:34:07 -07:00
jp9000
544975b4e7 added sizing/aspect ignore/positioning to graphics capture, added mouse to win8 capture, fixed push-to-talk volume, added push-to-talk delay 2012-12-16 22:27:41 -07:00
jp9000
307903f372 fixed a crash with audio levels, added the ability to crop win8 capture 2012-12-16 13:32:04 -07:00
jp9000
2573310d75 made volume controls linear again, updated win8 monitor capture 2012-12-15 16:53:33 -07:00