0
0
mirror of https://github.com/obsproject/obs-studio.git synced 2024-09-20 13:08:50 +02:00
Commit Graph

479 Commits

Author SHA1 Message Date
jp9000
8bb208a090 Make some minor adjustments to module UI code
Made it so that enum_ui returns a const pointer to a structure rather
than require an actual structure.

Changed a few of the descriptions that I missed.
2014-02-01 01:02:20 -07:00
jp9000
a12656bd91 Add module UI export capability
Add the ability to be able to call and use toolkit-specific or
program-specific user interface in modules.

User interface code can be either bundled with the module, or 'split'
out in to separate libraries (recommended).

There are three reasons why splitting is recommended:

  1.) It allows plugins to be able to create custom user interface for
      each toolkit if desired.

  2.) Often, UI will be programmed in one language (the language of the
      toolkit), and core logic may be programmed in another.  This
      allows plugins to keep the languages separated if necessary.

  3.) It prevents direct linkage of UI toolkits libraries with core
      module logic.

Splitting is not required, though is recommended if you want your plugin
to be more flexible with other user interface toolkits or programs.

Will implement a generic properties lookup next, which will be used for
automatic UI handling so that plugin UI isn't necessarily required.
2014-02-01 00:49:50 -07:00
Jim
17333ddfec Merge pull request #37 from BtbN/master
Improve ALL_BUILD.vcxproj.user copy check
2014-01-30 19:56:22 -08:00
BtbN
aec9e85b59 Improve ALL_BUILD.vcxproj.user copy check 2014-01-31 04:46:17 +01:00
Jim
b56a249f55 Merge pull request #35 from BtbN/master
git describe based version number support for CPack
2014-01-30 12:59:02 -08:00
jp9000
74032922bc Fix another bug (don't commit without compiling)
Also don't code in anger
2014-01-30 12:42:20 -07:00
jp9000
73d4e1331c And cover the one in scene_destroy 2014-01-30 12:41:11 -07:00
jp9000
7b37dc6cbb Oh and while we're at it I suppose another fix 2014-01-30 12:39:26 -07:00
jp9000
f26cb706c2 Clean up the previous commit a bit
The was_removed variable was rather unnecessary
2014-01-30 12:35:21 -07:00
jp9000
f2e1ce533c Use mutex instead of variable for RC check 2014-01-30 12:29:13 -07:00
jp9000
103ef75310 Improve thread safety for scene items
Scene items previously were removed by calling obs_sceneitem_destroy,
but this proved to be a potential race condition where two different
threads could try to destroy the same scene item at the same time.

Instead of doing that, reference counting is now used on scene items,
and an explicit obs_sceneitem_remove function is used instead for item
removal, which sets a 'removed' variable to ensure it can only be called
exactly one time.
2014-01-30 01:31:52 -07:00
jp9000
f419c9f154 Merge branch 'master' of https://github.com/jp9000/obs-studio 2014-01-29 18:32:01 -07:00
jp9000
3243a9f8c5 Fix the design flaw with obs_sceneitem_destroy
The previous commit used the scene as a  parameter to check to see if
the scene item was still present within the scene before destroying, but
this was actually unnecessary because the fault was because the destroy
signal was being triggered *before* the scene's mutex locked, thus
causing a race condition.  I changed the code so that it signals after
the lock instead of before, so the scene parameter should no longer be
necessary.
2014-01-29 18:27:42 -07:00
Palana
d095a4ae47 Fix obs_sceneitem_destroy for scenes with more than one scene item 2014-01-30 00:13:43 +01:00
Palana
31ceec04ce Lock graphics before trying to remove a scene item
Prevents another deadlock if removing the scene item triggers source
cleanup of a source with graphics resources
2014-01-29 22:54:05 +01:00
Palana
2fa208adfb Check if scene item is actually alive when calling obs_sceneitem_destroy
Prevents a double free in case the scene item was previously removed
2014-01-29 22:52:05 +01:00
Palana
af03444cbe Use recursive mutex for scene mutex
Fixes a deadlock when trying to remove a source from the GUI. The scene
item signal handlers would mark the source as removed which results in
the video thread also trying to run obs_sceneitem_destroy thereby
deadlocking the video thread (and the GUI thread)
2014-01-29 22:46:39 +01:00
Palana
13db68433d Improve multi instance support for osx desktop capture
Fixes behavior with multiple desktop captures in the same scene

Also create the dispatch_queue without a name to prevent name collisions
2014-01-29 19:42:36 +01:00
BtbN
a79124e413 Add guessed paths for Win8 and Win81 SDK to DirectX search paths 2014-01-29 14:56:40 +01:00
BtbN
8c80941530 Add support for "git describe" based version numbers.
Also, move cpack related code into its own module, to clean up the main CMakeLists.txt
2014-01-29 14:56:06 +01:00
Palana
ad4b581112 Improve setting type consistency 2014-01-29 08:40:04 +01:00
jp9000
9116be8d9c Improve safety for settings usage
- Add 'set_default' functions to obs-data.*.  These functions ensure
  that a paramter exists and that the parameter is of a specific type.
  If not, it will create or overwrite the value with the default setting
  instead.

  These functions are meant to be explicitly called before using any of
  the 'get' functions.  The reason why it was designed this way is to
  encourage defaults to be set in a single place/function.

  For example, ideal usage is to create one function for your data,
  "set_my_defaults(obs_data_t data)", set all the default values within
  that function, and then call that function on create/update, that way
  all defaults are centralized to a single place.

- Ensure that data passed to sources/encoders/outputs/etc is always
  valid, and not a null value.

- While I'm remembering, fix a few defaults of the main program config
  file data.
2014-01-28 18:41:24 -07:00
jp9000
c6300d0956 Add a couple more setting data safety measures
Prevent null dereferencing if data is null, instead just make the
functions return and ignore the get/set requests.
2014-01-28 15:45:30 -07:00
Jim
6c2242dea8 Merge pull request #33 from andy-kliman/master
I rebuilt obs.icns. Now it corresponds to Table 5-1:
2014-01-28 14:34:25 -08:00
Palana
fdfd96b783 Rename osx desktop capture functions to fix dynamic loading 2014-01-28 23:14:02 +01:00
Palana
e430652d0f Add explicit Cocoa dependency for osx desktop capture test
Fixes build due to missing objective c functions on some configurations
2014-01-28 23:14:01 +01:00
Jim
4f8690985a Merge pull request #34 from BtbN/master
Include $ORIGIN in portable mode on unix
2014-01-28 14:12:20 -08:00
BtbN
b4d31f4e56 Change library search order to match include search order 2014-01-28 23:07:49 +01:00
BtbN
074f9627b7 Fixup OSX Rpath for imported external libraries on install 2014-01-28 23:07:49 +01:00
BtbN
19f0a30160 Include $ORIGIN in portable mode on unix 2014-01-28 14:15:46 +01:00
jp9000
197c0b1fdd Fix a few bugs with the new data interface
There were some possibilities of NULL pointer dereferencing.  Also,
changed one small function to inline.
2014-01-28 01:51:25 -07:00
jp9000
7e58fecc86 Check iosurf dependency in test-input cmake files 2014-01-28 00:06:46 -07:00
jp9000
95154f33c8 Fix cmake files for non-mac targets (broke it) 2014-01-27 23:53:44 -07:00
jp9000
0b87391ac8 Merge branch 'osx-monitor-capture' of https://github.com/jp9000/obs-studio 2014-01-27 23:39:37 -07:00
jp9000
6c44291693 Implement settings interface for plugins
Add a fairly easy to use settings interface that can be passed to
plugins, and replaced the old character string system that was being
used before.  The new data interface allows for an easier method of
getting/altering settings for plugins, and is built to be serializable
to/from JSON.

Also, removed another wxFormBuilder file that was no longer in use.
2014-01-27 23:14:58 -07:00
jp9000
de288ac541 Rename obs_data structure to obs_program_data
I'm doing this because I might create another data structure called
obs_data for a different purpose.  That and obs_program_data feels a bit
less vague for what it does.
2014-01-27 09:07:13 -07:00
jp9000
563613db8f Rename obs-data.h to obs-internal.h
Renaming obs-data.h to avoid confusion about its usage
2014-01-26 18:48:14 -07:00
jp9000
a5372e9757 Finish the rest of the settings dialog code
- Move over the last of the original settings dialog code to QT.  It was
  actually a bit easier to write in the QT version.  wxWidgets was
  definitely not ideal for that because the pages would fully
  create/destroy every time.

- [Win32] Fix os_dlopen so that it only appends .dll if not present

- [MacOS] Fix name dialog text edit widget issue (it would be better if
  we could just use the list widget for editing labels, will have to
  look in to that in the future)

- Tweak the settings UI a bit more and make 30 FPS default

- Add a macro to convert a QString to a UTF-8 const char * string

- Rename build/plugins to build/obs-plugins

- Remove the last of the wxWidgets code
2014-01-26 15:36:15 -07:00
Anry
842b8c8591 obs.icns now corresponds to Table 5-1:
icon_512x512@2x	-	1024 x 1024
icon_512x512	-	512 x 512
icon_256x256@2x	-	512 x 512
icon_256x256	-	256 x 256
icon_128x128@2x	-	256 x 256
icon_128x128	-	128 x 128
icon_32x32@2x	-	64 x 64
icon_32x32	-	32 x 32
icon_16x16@2x	-	32 x 32
icon_16x16	-	16 x 16
2014-01-26 18:28:28 +04:00
Zachary Lund
cc44c93fbf Fixed missed boolean check 2014-01-26 01:53:59 -06:00
Zachary Lund
488c90b3d2 Removed mercurial leftovers 2014-01-26 00:53:12 -06:00
computerquip
2d5758f758 Merge pull request #32 from jp9000/alt-ogl-loader
Alternative OGL loader. GLEW was bulky, slow, and sometimes didn't do its job that well. This is the replacement.
2014-01-25 22:05:41 -08:00
Zachary Lund
666f0be14f Merge branch 'alt-ogl-loader' of https://github.com/jp9000/obs-studio into alt-ogl-loader 2014-01-25 23:59:26 -06:00
Zachary Lund
ae17c457a7 Regenerated files 2014-01-25 23:58:43 -06:00
Zachary Lund
f4379d7889 Changed constness on passed argument, updated VC++ project files 2014-01-25 23:23:26 -06:00
Zachary Lund
1c48834cb5 Fixed signedness issue on GLX 2014-01-25 22:27:02 -06:00
Zachary Lund
469f217e6b Removed tools used to generate the GL headers/implementations as we never use them to build 2014-01-25 22:26:55 -06:00
Zachary Lund
001f0b10a4 Fixed Windows goofy macros 2014-01-25 22:26:55 -06:00
Zachary Lund
f33e693a6e Fixed cmake for Windows 2014-01-25 22:26:55 -06:00
Zachary Lund
74ab96a3ad I removed GLEW, added glLoadGen (renamed to GL here), and added implementations for all platforms. Hopefully this goes better than GLAD did. 2014-01-25 22:26:43 -06:00