This allows a clean shutdown during a blocking connnect(),
recv() or send() call during RTMP initialization. Previously
OBS would completely block, waiting on the socket to respond.
Changed it so that timestamps do not "reset" if under the expected
value. Seems that doing this prevent a lot of timestamp "jumps" and
allows data to flow far more smoothly, as long as it's within the
expected broundries.
Had to make a ridiculous hack to get more usable variables in the class
without breaking API. It's a totally disgusting hack, but it works.
Replaced the AudioSource::resampler variable to be a pointer to newer
variables. The reason this hack had to be done in the first place is
because I directly exposed data in the base class instead of using a
forward. Forward pointers are always far more safe and prevent API
breakage. This is one thing I really dislike about C++, you modify the
class what so ever and it will break API. I just don't like C++ when
used for libraries, but again I could have avoided it by simply handling
it better, so it was really my fault for having been so careless with it
in the first place.
Right now, the state of things is that if the user was running an nvidia
laptop, he/she "had" to use the first adapter, and then fool with the
nvidia control panel to get the nvidia working properly.
This change makes it so that the nvidia optimus hint will be activated
and the first adapter will be forced if the user selects the nvidia
adapter in OBS' video adapter drop down, making it much easier for users
to deal with the nvidia laptop issue.
Properly hide the "Keep recording" checkbox when switching to file
output only, update the Start Streaming/Start Recording buttons when
switching modes in the settings.
Move the keep recording setting from global.ini to Broadcast Settings
(profile dependent), make it default to off, comment out the old
dashboard link code for now.
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.
- When two push-to-talk hotkeys are in use at once, the first hotkey
that was released would turn off push-to-talk. Now, it makes sure
that both hotkeys must be released before turning it off.
- I needed to change the parameter for my hack, so I'm just going to
create a new function instead, QueryAudio2. C++ mangling and API
breakage makes me most displeased.
- Woops, don't use global audio time for sorting, use the latest audio
timestamp from that specific device.
- Also, made it so lastSentTimestamp is only done when data is actually
used, accidentally put it in the wrong scope.
- 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
String::operator!=, String::operator==, and String::Compare functions
were all originally functions that returned BOOL. I changed them to
return native 'bool' instead without realizing that it would break the
API. So, sadly, I have to change them back to BOOL to prevent
incompatibilities with existing plugins.
When the user has set the mode to "record to file only", make it so
that the "Start/Stop Recording" button is enabled, and that the
"Start/Stop Streaming" button is disabled. Having both buttons
enabled when in 'record only' mode is just a bit confusing.
This branch fixes the issue of your recordings ending every time the
network stream is disconnection.
This commit is a squash of the following commits on the branch:
tweak the button positions a little bit
Added OnOBSStatus plugin callback
Enables plugins to recreate the (LIVE + REC) display
Skip ReportStreamStatus callbacks if there is no actual stream
Fix the status bar for real this time
Make the status bar keep updating when not live
Fixed exit cleanup while streaming/recording
Fix Stop() behavior and stream status message
Continue recording even if the stream goes offline
Requires setting KeepRecordingOnStopStreaming to 1 in global.ini to test
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)