Commit Graph

27 Commits

Author SHA1 Message Date
Jonathan Thomas
57a0bae9ac Refactor of Settings to no longer duplicate them in the *.h and Instance() method. Also changing FF_THREADS and OMP_THREADS to use # of processors on device. 2025-06-06 15:26:40 -05:00
Jonathan Thomas
5cdf42784c Updating default cache settings to 24 (min preroll), 48 (max preroll), 300 (max frames), and 0.7 (percent ahead) 2022-10-13 10:04:48 -05:00
Jonathan Thomas
8ac1589b2d Optimizing caching thread to exclude frames where no clips exist, and simplify some of the caching loop logic 2022-10-04 18:35:16 -05:00
Jonathan Thomas
969a2015bf Increasing max video cache frames, moving percentage-ahead caching to a setting, fixing a calculation error on bytes per frame 2022-09-20 16:55:07 -05:00
Jonathan Thomas
7c2a205d5e Adding new settings, to control how video caching works, and how many frames to pre-roll and cache 2022-09-15 17:53:44 -05:00
Jonathan Thomas
9eda757885 Merge branch 'develop' into audio-devices
# Conflicts:
#	src/AudioBufferSource.cpp
#	src/AudioReaderSource.cpp
#	src/AudioReaderSource.h
#	src/Clip.cpp
#	src/Frame.cpp
#	src/Qt/AudioPlaybackThread.h
#	src/audio_effects/Compressor.h
#	src/audio_effects/Delay.h
#	src/audio_effects/Echo.h
#	src/audio_effects/Expander.h
2021-12-02 22:05:19 -06:00
Frank Dana
59138ea3e4 Adopt license management via Reuse project/tool (#711)
* reuse-managed license/copyright headers

reuse is a tool for compliance with the REUSE recommendations. See
<https://reuse.software/> for more information, and
<https://reuse.readthedocs.io/> for the online documentation.

* Set jsoncpp license
* Add MIT license for Decklink sources
* Explicitly license examples/
  - Add headers to source files
  - Change blanket licensing in .reuse/dep5 to only cover binary media
  - Import CC-BY-3.0 license and assign to sintel_trailer
2021-10-16 01:26:26 -04:00
FeRD (Frank Dana)
6aab6fd957 Audio: New device name lookup
- A new AudioDevices class replaces the AudioDeviceInfo struct.
  It has a single method, getNames(), which:
  * creates an AudioDeviceManager (NOT using the singleton)
  * scans for available devices
  * returns the results as a std::vector containing
    std::pair<std::string, std::string> objects

  (The AudioDevices device manager is never initialize()d, so
  no devices are opened; it should be safe to use even DURING
  playback, without disruption.)

  By using STL containers (rather than a custom struct) to return
  the results, Python is able to consume the output as a native
  list of tuples.

  AudioDeviceInfo is still present for compatibility, but deprecated.

- Eliminated some unnecessary conversions (like):
  * calls to std::string::c_str, when passing to juce::String.
    juce::String accepts std::string directly.
  * calls to juce::String::toRawUTF8, when creating std::string.
    There's a juce::String::ToStdString, which is better.
2021-08-24 13:11:00 -04:00
FeRD (Frank Dana)
37f5e4dfbf Settings: Support LIBOPENSHOT_DEBUG envvar
- Setting LIBOPENSHOT_DEBUG to any value in the process environment
  activates debug logging to stderr.
2021-04-27 16:19:31 -04:00
Jonathan Thomas
3daa5bdb7b Large refactor of OpenMP integration (or rather the removal of OpenMP on the Timeline and FFmpeg-related classes). The logic behind this decision, was based on profiling libopenshot and the amount of wasted CPU idle time on all the various threads. The slow code is still synchronous, and all the threads must wait on each other, adding additional overhead. So, removing lots of unneeded threads, and simplifying the underlying Timeline->Clip->FFmpegReader flow. Also, removed 2 calls to QPainter::drawImage, by improving the flexibility of Clip->GetFrame. 2021-02-17 19:44:44 -06:00
Jonathan Thomas
896b307381 Merge pull request #422 from ferdnyc/debug-to-stderr
ZmqLogger: Add optional dumping to stderr
2020-10-29 17:49:49 -05:00
FeRD (Frank Dana)
f55c563ba5 Merge branch 'develop' into debug-to-stderr 2020-10-19 16:38:54 -04:00
FeRD (Frank Dana)
a1e44edad4 Merge branch 'develop' into clip-refactor-keyframes 2020-10-19 16:28:49 -04:00
Jonathan Thomas
8387b124ad Large refactor of Timeline, TimelineBase, ClipBase, and Clip, to allow a Clip access to the parent timeline instance (if available), and thus, certain properties (preview size, timeline FPS, etc...). This allows for a simpler rendering of Clip keyframes (during the Clip::GetFrame method), and a simpler Timeline class, that can change the preview window size dynamically and no longer requires a Singleton Settings class.
- Also removed "crop" from Clip class, as it was never implmeneted correctly, and we have a fully functional "crop" effect when needed
 - Added caching to Clip class, to optimize previewing of cached frames (much faster than previous)
2020-10-19 16:05:01 -04:00
FeRD (Frank Dana)
aa40ea29e0 Update include paths in all source/header files 2020-10-18 07:43:37 -04:00
FeRD (Frank Dana)
fc18366843 ZmqLogger: Add optional dumping to stderr
Add an openshot::Settings boolean `DEBUG_TO_STDERR`, which when
set true will direct all AppendDebugMethod() messages to std::clog,
in addition to (possibly) being sent over the ZeroMQ wire.
2020-02-01 02:00:43 -05:00
FeRD (Frank Dana)
f170fdd009 Update copyright range to current year 2019-06-11 06:48:32 -04:00
FeRD (Frank Dana)
0327c2ab5c Remove license block from documentation comment 2019-06-09 08:31:04 -04:00
Jonathan Thomas
140fbaddff Added new AudioDeviceInfo struct, and populate a vector of them on QtPlayer initialization. This allows a user to overwrite the preferred audio device by using the setting PLAYBACK_AUDIO_DEVICE_NAME. 2019-04-23 16:45:02 -05:00
Jonathan Thomas
79335277cb Removing old commented out code 2019-04-21 14:37:06 -05:00
eisneinechse
65d9134722 Remove DECODE varaible.
Turn out that a buggy graphic driver was the problem.
2019-04-21 12:18:44 -07:00
eisneinechse
825e38ac9d Removing old way to select hardware support
Removing the decode setting makes hardware supported decode break.
There must be some hidden dependency on that variable somewhere
which might also be responsible for the problems with nVidia on
Linux. TODO Remove the dependency
2019-04-21 10:04:24 -07:00
eisneinechse
2e635e3d87 Formating and Cleanup
Fix forgotten break in switch
2019-01-31 09:42:26 -08:00
eisneinechse
596ae0efac More changes to move to Settings, still needs work 2019-01-30 20:44:36 -08:00
eisneinechse
2ca84217bc First changes to use Settings instead of GetEnv 2019-01-30 09:58:54 -08:00