Browse Source

lovr.filesystem.mount root; blocksize system limit;

bjorn 6 years ago
parent
commit
74d63990d7
3 changed files with 37 additions and 12 deletions
  1. 17 6
      api/init.lua
  2. 9 0
      api/lovr/filesystem/mount.lua
  3. 11 6
      api/lovr/graphics/getSystemLimits.lua

+ 17 - 6
api/init.lua

@@ -5188,6 +5188,12 @@ return {
                   type = "boolean",
                   description = "Whether the archive will be added to the end or the beginning of the search path.",
                   default = "false"
+                },
+                {
+                  name = "root",
+                  type = "string",
+                  description = "A subdirectory inside the archive to use as the root.  If `nil`, the actual root of the archive is used.",
+                  default = "nil"
                 }
               },
               returns = {
@@ -7772,14 +7778,19 @@ return {
                   description = "The table of limits.",
                   table = {
                     {
-                      name = "pointsize",
+                      name = "anisotropy",
                       type = "number",
-                      description = "The maximum size of points, in pixels."
+                      description = "The maximum anisotropy value supported by `Texture:setFilter`."
                     },
                     {
-                      name = "texturesize",
+                      name = "blocksize",
                       type = "number",
-                      description = "The maximum width or height of textures, in pixels."
+                      description = "The maximum size of a uniform ShaderBlock, in bytes."
+                    },
+                    {
+                      name = "pointsize",
+                      type = "number",
+                      description = "The maximum size of points, in pixels."
                     },
                     {
                       name = "texturemsaa",
@@ -7787,9 +7798,9 @@ return {
                       description = "The maximum MSAA value supported by `lovr.graphics.newTexture`."
                     },
                     {
-                      name = "anisotropy",
+                      name = "texturesize",
                       type = "number",
-                      description = "The maximum anisotropy value supported by `Texture:setFilter`."
+                      description = "The maximum width or height of textures, in pixels."
                     }
                   }
                 }

+ 9 - 0
api/lovr/filesystem/mount.lua

@@ -23,6 +23,15 @@ return {
       description = [[
         Whether the archive will be added to the end or the beginning of the search path.
       ]]
+    },
+    {
+      name = 'root',
+      type = 'string',
+      default = 'nil',
+      description = [[
+        A subdirectory inside the archive to use as the root.  If `nil`, the actual root of the
+        archive is used.
+      ]]
     }
   },
   returns = {

+ 11 - 6
api/lovr/graphics/getSystemLimits.lua

@@ -13,14 +13,19 @@ return {
       description = 'The table of limits.',
       table = {
         {
-          name = 'pointsize',
+          name = 'anisotropy',
           type = 'number',
-          description = 'The maximum size of points, in pixels.'
+          description = 'The maximum anisotropy value supported by `Texture:setFilter`.'
         },
         {
-          name = 'texturesize',
+          name = 'blocksize',
           type = 'number',
-          description = 'The maximum width or height of textures, in pixels.'
+          description = 'The maximum size of a uniform ShaderBlock, in bytes.'
+        },
+        {
+          name = 'pointsize',
+          type = 'number',
+          description = 'The maximum size of points, in pixels.'
         },
         {
           name = 'texturemsaa',
@@ -28,9 +33,9 @@ return {
           description = 'The maximum MSAA value supported by `lovr.graphics.newTexture`.'
         },
         {
-          name = 'anisotropy',
+          name = 'texturesize',
           type = 'number',
-          description = 'The maximum anisotropy value supported by `Texture:setFilter`.'
+          description = 'The maximum width or height of textures, in pixels.'
         }
       }
     }