bjorn 4 лет назад
Родитель
Сommit
fc889f818f
4 измененных файлов с 888 добавлено и 330 удалено
  1. 878 324
      api/init.lua
  2. 4 3
      api/lovr/audio/Source/isEffectEnabled.lua
  3. 4 2
      api/lovr/audio/Source/setEffectEnabled.lua
  4. 2 1
      api/lovr/audio/newSource.lua

Разница между файлами не показана из-за своего большого размера
+ 878 - 324
api/init.lua


+ 4 - 3
api/lovr/audio/Source/isEffectEnabled.lua

@@ -18,9 +18,10 @@ return {
   },
   },
   notes = [[
   notes = [[
     The active spatializer will determine which effects are supported.  If an unsupported effect is
     The active spatializer will determine which effects are supported.  If an unsupported effect is
-    enabled on a Source, no error will be reported.  Instead, it will be silently ignored (this
-    function will still report it as enabled).
+    enabled on a Source, no error will be reported.  Instead, it will be silently ignored.  See
+    `lovr.audio.getSpatializer` for a table showing the effects supported by each spatializer.
 
 
-    TODO: expose a table of supported effects for spatializers in docs or from Lua.
+    Calling this function on a Source that was created with `{ effects = false }` will always return
+    false.
   ]]
   ]]
 }
 }

+ 4 - 2
api/lovr/audio/Source/setEffectEnabled.lua

@@ -17,8 +17,10 @@ return {
   returns = {},
   returns = {},
   notes = [[
   notes = [[
     The active spatializer will determine which effects are supported.  If an unsupported effect is
     The active spatializer will determine which effects are supported.  If an unsupported effect is
-    enabled on a Source, no error will be reported.  Instead, it will be silently ignored.
+    enabled on a Source, no error will be reported.  Instead, it will be silently ignored.  See
+    `lovr.audio.getSpatializer` for a table showing the effects supported by each spatializer.
 
 
-    TODO: expose a table of supported effects for spatializers in docs or from Lua.
+    Calling this function on a Source that was created with `{ effects = false }` will throw an
+    error.
   ]]
   ]]
 }
 }

+ 2 - 1
api/lovr/audio/newSource.lua

@@ -32,7 +32,8 @@ return {
           description = [[
           description = [[
             A table of `Effect`s to enable.  Keys can be integers (list) or effect names (map), or a
             A table of `Effect`s to enable.  Keys can be integers (list) or effect names (map), or a
             combination of both.  The special value `false` can be used to completely disable
             combination of both.  The special value `false` can be used to completely disable
-            effects, bypassing the spatializer entirely.  `true` will enable all effects.
+            effects, bypassing the spatializer entirely and throwing an error when trying to enable
+            effects.  `true` will enable all effects.
           ]]
           ]]
         }
         }
       }
       }

Некоторые файлы не были показаны из-за большого количества измененных файлов