EngineStreamingGetBufferSize: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
Fernando187 (talk | contribs) (Remove obsolete Requirements section) |
||
(One intermediate revision by one other user not shown) | |||
Line 4: | Line 4: | ||
==Syntax== | ==Syntax== | ||
<syntaxhighlight lang="lua"> | <syntaxhighlight lang="lua"> | ||
int engineStreamingGetBufferSize() | |||
</syntaxhighlight> | </syntaxhighlight> | ||
{{OOP||[[EngineStreaming]]:getBufferSize|bufferSize|engineStreamingSetBufferSize}} | {{OOP||[[EngineStreaming]]:getBufferSize|bufferSize|engineStreamingSetBufferSize}} | ||
Line 26: | Line 26: | ||
end, false, false) | end, false, false) | ||
</syntaxhighlight> | </syntaxhighlight> | ||
==See Also== | ==See Also== | ||
{{Engine functions}} | {{Engine functions}} |
Latest revision as of 17:33, 7 November 2024
Get the streaming buffer size [not maximum memory size]
Syntax
int engineStreamingGetBufferSize()
OOP Syntax Help! I don't understand this!
- Method: EngineStreaming:getBufferSize(...)
- Variable: .bufferSize
- Counterpart: engineStreamingSetBufferSize
Returns
The streaming buffer size. It is always a positive non-zero number.
Example
This example adds a command that can be used to change the streaming buffer size, and display the previous value.
addCommandHandler("sbs", function(_, sizeMB) if tonumber(sizeMB) then if engineStreamingSetBufferSize(tonumber(sizeMB) * 1024 * 1024) then -- Convert MB to Bytes outputChatbox("The streaming buffer size has been changed from " .. math.floor(engineStreamingGetBufferSize() / 1024 / 1024) .. " MB to " .. sizeMB .. " MB") else outputChatbox("Not enough memory!") end else outputChatbox("Please enter a numeric value!") end end, false, false)
See Also
- engineAddImage
- engineApplyShaderToWorldTexture
- engineFreeModel
- engineGetModelFlags
- engineGetModelIDFromName
- engineGetModelLODDistance
- engineGetModelNameFromID
- engineGetModelPhysicalPropertiesGroup
- engineGetModelTextureNames
- engineGetModelTextures
- engineGetModelTXDID
- engineGetModelVisibleTime
- engineGetObjectGroupPhysicalProperty
- engineGetSurfaceProperties
- engineGetVisibleTextureNames
- engineImageGetFilesCount
- engineImageGetFiles
- engineImageGetFile
- engineImageLinkDFF
- engineImageLinkTXD
- engineImportTXD
- engineLoadCOL
- engineLoadDFF
- engineLoadIMG
- engineLoadIFP
- engineLoadTXD
- engineRemoveImage
- engineRemoveShaderFromWorldTexture
- engineReplaceAnimation
- engineReplaceCOL
- engineReplaceModel
- engineRequestModel
- engineResetModelFlags
- engineResetModelLODDistance
- engineResetSurfaceProperties
- engineRestoreAnimation
- engineRestoreCOL
- engineRestoreDFFImage
- engineRestoreModel
- engineRestoreModelPhysicalPropertiesGroup
- engineRestoreObjectGroupPhysicalProperties
- engineRestoreTXDImage
- engineRestreamWorld
- engineSetAsynchronousLoading
- engineSetModelFlag
- engineSetModelFlags
- engineSetModelLODDistance
- engineSetModelPhysicalPropertiesGroup
- engineSetModelVisibleTime
- engineSetObjectGroupPhysicalProperty
- engineSetSurfaceProperties
- engineStreamingFreeUpMemory
- engineStreamingGetUsedMemory