stream_configuration.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. /*
  2. * This file is part of the FreeStreamer project,
  3. * (C)Copyright 2011-2018 Matias Muhonen <mmu@iki.fi> 穆马帝
  4. * See the file ''LICENSE'' for using the code.
  5. *
  6. * https://github.com/muhku/FreeStreamer
  7. */
  8. #ifndef ASTREAMER_STREAM_CONFIGURATION_H
  9. #define ASTREAMER_STREAM_CONFIGURATION_H
  10. #import <CoreFoundation/CoreFoundation.h>
  11. namespace astreamer {
  12. struct Stream_Configuration {
  13. unsigned bufferCount;
  14. unsigned bufferSize;
  15. unsigned maxPacketDescs;
  16. unsigned httpConnectionBufferSize;
  17. double outputSampleRate;
  18. long outputNumChannels;
  19. int bounceInterval;
  20. int maxBounceCount;
  21. int startupWatchdogPeriod;
  22. int maxPrebufferedByteCount;
  23. bool usePrebufferSizeCalculationInSeconds;
  24. bool usePrebufferSizeCalculationInPackets;
  25. int requiredInitialPrebufferedByteCountForContinuousStream;
  26. int requiredInitialPrebufferedByteCountForNonContinuousStream;
  27. int requiredPrebufferSizeInSeconds;
  28. int requiredInitialPrebufferedPacketCount;
  29. CFStringRef userAgent;
  30. CFStringRef cacheDirectory;
  31. CFDictionaryRef predefinedHttpHeaderValues;
  32. bool cacheEnabled;
  33. bool seekingFromCacheEnabled;
  34. bool automaticAudioSessionHandlingEnabled;
  35. bool enableTimeAndPitchConversion;
  36. bool requireStrictContentTypeChecking;
  37. int maxDiskCacheSize;
  38. static Stream_Configuration *configuration();
  39. private:
  40. Stream_Configuration();
  41. ~Stream_Configuration();
  42. Stream_Configuration(const Stream_Configuration&);
  43. Stream_Configuration& operator=(const Stream_Configuration&);
  44. };
  45. } // namespace astreamer
  46. #endif // ASTREAMER_STREAM_CONFIGURATION_H