Browse Source

libobs: Add preprocessor directive for AutoRelease types

Since these helpers come from obs-websocket, obs-websocket needs a way
to disable its own helpers if OBS is new enough to include them
already.
tt2468 3 years ago
parent
commit
647fb1376d
1 changed files with 1 additions and 0 deletions
  1. 1 0
      libobs/obs.hpp

+ 1 - 0
libobs/obs.hpp

@@ -47,6 +47,7 @@ using OBSWeakEncoder = OBSRef<obs_weak_encoder_t *, obs_weak_encoder_addref,
 using OBSWeakService = OBSRef<obs_weak_service_t *, obs_weak_service_addref,
 			      obs_weak_service_release>;
 
+#define OBS_AUTORELEASE
 inline void ___source_dummy_addref(obs_source_t *){};
 inline void ___scene_dummy_addref(obs_scene_t *){};
 inline void ___sceneitem_dummy_addref(obs_sceneitem_t *){};