Commit Graph

8621 Commits

Author SHA1 Message Date
Klaus Basan
09e65a2525 Ref T739, renamed CContext -> IContext
This reflects the purpose better, it is a base class for all context interfaces
2019-10-11 19:00:35 +01:00
Klaus Basan
4c170e0ac4 Ref T730, reply in CAfvClient can be nullptr when called from another thread
* nullptr is a normal condition
* see https://discordapp.com/channels/539048679160676382/623947987822837779/629780397986676766
2019-10-11 19:00:34 +01:00
Klaus Basan
226b601565 Ref T730, log category 2019-10-11 19:00:34 +01:00
Klaus Basan
27fedad3fd Ref T730, renamed to CApiServerConnection 2019-10-11 19:00:34 +01:00
Klaus Basan
61d82ab780 Ref T570, prepared ApiServerConnection for "threaded AFV client"
* use get/post/deleteFromNetwork function in sApp (calling QAM in coorect thread)
* removed timer, use QDateTime::currentMSecsSinceEpoch - one member less causing issues in threaded environment
* using CLogMessage instead of qDebug/qWarning
* unified log messages
2019-10-11 19:00:34 +01:00
Klaus Basan
ea8e27cc9b Ref T730, obtain duration from "swift modified" QNetworkReply 2019-10-11 19:00:34 +01:00
Klaus Basan
ff6b7f8deb Ref T730, added deleteResourceFromNetwork and modified CSlot (directly accept object witb std::function) 2019-10-11 19:00:34 +01:00
Klaus Basan
6e9fa0b2ad Ref T730, style 2019-10-11 19:00:33 +01:00
Klaus Basan
fee8852762 Ref T730, increase buffer size to avoid buffer issues (temp workaround)
see https://discordapp.com/channels/539048679160676382/623947987822837779/628874110973247499
2019-10-11 19:00:32 +01:00
Klaus Basan
37a5da4e04 Ref T731, AFV sample default value for user name 2019-10-11 19:00:32 +01:00
Klaus Basan
89725c3bb4 Ref T730, also return an output device if there is no exact match 2019-10-11 19:00:32 +01:00
Klaus Basan
5d9ea83b93 Ref T730, improved threaded tone player
* allow to re-init and get device info
* mutable mutex
2019-10-11 19:00:32 +01:00
Roland Rossgotterer
90e87835fc [AFV] Select audio device based on situational need
For AFV itself, a low latency device is required (which on Windows most likely will pick WASAPI).
For notifications and effects, the most compatible device is required (which on Windows will most likely fall back to QWindowsAudio).
2019-10-11 19:00:32 +01:00
Roland Rossgotterer
18ec101391 Don't push duplicated audio devices into the list 2019-10-11 19:00:32 +01:00
Roland Rossgotterer
a2e3700739 Replace QAudioDeviceInfo with CAudioDeviceInfo where possible
QAudioDeviceInfo is a low level technical class, which shouldn't be used in higher level code. Remove it from all APIs
where possible and just create it in order to interface with QAudio
2019-10-11 19:00:31 +01:00
Roland Rossgotterer
8656131eb1 Remove all obsolete vatlib voice classes 2019-10-11 19:00:31 +01:00
Roland Rossgotterer
c759d45bb0 [AFV] Remove obsolete VVL device index from CAudioDeviceInfo 2019-10-11 19:00:31 +01:00
Roland Rossgotterer
33d125c121 [AFV] Remove unnecessary functions 2019-10-11 19:00:31 +01:00
Roland Rossgotterer
ac833910c8 [AFV] Optimize loading and sharing of CResourceSound objects
- Loading is now happening in a worker to not block the main thhread
- The internal data is shared between all instances of the class.
2019-10-11 19:00:30 +01:00
Klaus Basan
b65b2caa76 Ref T730, use m_deviceInfo.nearestFormat (makes player working with WSAPI plugin) 2019-10-11 19:00:30 +01:00
Klaus Basan
6111c428e9 Ref T730, style and removed "old voice code" 2019-10-11 19:00:30 +01:00
Roland Rossgotterer
8d84dcbe08 [AFV] Make sure all QObjects below AfvClient have a parent 2019-10-11 19:00:30 +01:00
Roland Rossgotterer
240df93406 [AFV] Change output format and processing to 32 bit float
32 bit float is what is used in C# reference and has a much higher
dynamic range. 16 bit integer was clipping very often with all the VHF
simulation applied.
2019-10-11 19:00:29 +01:00
Roland Rossgotterer
fbb126370c [AFV] Use distance ratio 1.0 in loopback mode
Distance ratio 1.0 means same position as sending position, decreasing 
ratio means increasing distance.
2019-10-11 19:00:29 +01:00
Roland Rossgotterer
bff4eeb416 [AFV] Update effects after adding new samples
This is necessary to regularly update the distance effects while moving
2019-10-11 19:00:29 +01:00
Roland Rossgotterer
ec68e756cd [AFV] Port NAudio BiQuadFilter 2019-10-11 19:00:28 +01:00
Roland Rossgotterer
574370579d [AFV] Apply BiQuadFilters on float samples 2019-10-11 19:00:28 +01:00
Roland Rossgotterer
d757b8977f [AFV] Reset pointer after stopping audio output 2019-10-11 19:00:27 +01:00
Roland Rossgotterer
df30a010b5 [AFV] Fix includes 2019-10-11 19:00:27 +01:00
Roland Rossgotterer
1f2d4a10b1 [AFV] Add HF simulation 2019-10-11 19:00:27 +01:00
Roland Rossgotterer
2c1067b27e [AFV] Update CEqualizerSampleProvider to VHF 4.0 2019-10-11 19:00:24 +01:00
Klaus Basan
0e4c1f958b Ref T730, some adjustments for CNotification for testing with WSAPI 2019-10-11 19:00:24 +01:00
Klaus Basan
be4776ce85 Ref T730, removed voice room selection in ATC station component and settings 2019-10-11 19:00:24 +01:00
Klaus Basan
96669ea507 Ref T730, minor tweak to "better see FSD callsign" 2019-10-11 19:00:24 +01:00
Klaus Basan
91b65fa2b6 Ref T730, AFV client fixes
* correct quint32 for frequency
* make sure frequencies are not updated twice, only update position
* re-init transceivers if stopped and started again
2019-10-11 19:00:23 +01:00
Klaus Basan
5c56715c28 Ref T730, add AFV test server in "test server list" 2019-10-11 19:00:23 +01:00
Klaus Basan
30158975b6 Ref T731, correctly set "disable VHF simulation" checkbox 2019-10-11 19:00:23 +01:00
Klaus Basan
cf6434f49b Ref T730, fixed using wrong member "m_outputVolume", added new member "m_outputVolumeDb" 2019-10-11 19:00:23 +01:00
Klaus Basan
3ddded423a Ref T730, style 2019-10-11 19:00:22 +01:00
Klaus Basan
09b38b4e6d Ref T730, function to check range for input/output volume 2019-10-11 19:00:22 +01:00
Klaus Basan
905c487451 Ref T737, stop output device 2019-10-11 19:00:21 +01:00
Klaus Basan
7d04ca6435 Ref T730, register metatype so struct can be used with signals
Remark: Unregistered it only works for direct connections
2019-10-11 19:00:21 +01:00
Klaus Basan
0aeeaa5aef Ref T730, do NOT play own PTT, AFV plays PTT 2019-10-11 19:00:21 +01:00
Klaus Basan
bde7baf84d Ref T730, style 2019-10-11 19:00:21 +01:00
Klaus Basan
c1470f6069 Ref T730, removed voice vatlib 2019-10-11 19:00:20 +01:00
Klaus Basan
5f6aebebe8 Ref T730, replaced uint array by vector to avoid memory leak
* the heap array was not deleted
* using QVector<uint> now
* const correctness
2019-10-11 19:00:20 +01:00
Klaus Basan
c3684a2f8c Ref T731, added namespace for utility functions 2019-10-11 19:00:19 +01:00
Klaus Basan
9a4fe0ea48 Ref T732, improved simulator type resolution for network 2019-10-11 19:00:19 +01:00
Klaus Basan
1ffedcb252 Ref T731, minor UI tweaks 2019-10-11 19:00:18 +01:00
Klaus Basan
a076705d77 Ref T731, changed Samples to use settings and new file names 2019-10-11 19:00:18 +01:00