sizeof
Definition
-- @/=[C]:-1
function sizeof(...)
Callers
@/lua/vehicle/extensions/tech/LINBus/LINBusPeak.lua
// pMsgBuff must be an array of 'iMaxCount' entries (must have at least
// a size of iMaxCount * sizeof(TLINRcvMsg) bytes).
// The size 'iMaxCount' of the array = max. messages that can be received.
@/lua/ge/extensions/editor/gen/exp_meshexplorer.lua
local floatByteSize = ffi.sizeof('float')
lo('??+++++++++++++ MI:'..lastMeshInfo.verticesCount..':'..tostring(vertices))
@/lua/ge/extensions/editor/dynamicDecals/layerStack.lua
if payload~=nil then
assert(payload.DataSize == ffi.sizeof(payloadSize))
local data = jsonDecode(ffi.string(payload.Data))
local payload = ffi.new(payloadSize)
ffi.copy(payload, jsonEncode({from = k, fromParentUid = parentUid}), ffi.sizeof(payloadSize))
im.SetDragDropPayload(layerDragDropType, payload, ffi.sizeof(payloadSize))
ffi.copy(payload, jsonEncode({from = k, fromParentUid = parentUid}), ffi.sizeof(payloadSize))
im.SetDragDropPayload(layerDragDropType, payload, ffi.sizeof(payloadSize))
im.TextUnformatted(layer.name)
if payload~=nil then
assert(payload.DataSize == ffi.sizeof(payloadSize))
local data = jsonDecode(ffi.string(payload.Data))
if payload~=nil then
assert(payload.DataSize == ffi.sizeof(payloadSize))
local data = jsonDecode(ffi.string(payload.Data))
if payload~=nil then
assert(payload.DataSize == ffi.sizeof(payloadSize))
local data = jsonDecode(ffi.string(payload.Data))
@/lua/ge/extensions/util/export.lua
local base64Prefix = "data:application/octet-stream;base64,"
local floatByteSize = ffi.sizeof('float')
local unsignedIntByteSize = ffi.sizeof('unsigned int')
local floatByteSize = ffi.sizeof('float')
local unsignedIntByteSize = ffi.sizeof('unsigned int')
@/lua/vehicle/protocols.lua
protocol.packet = ffi.new(protocol.structName)
protocol.packetSize = ffi.sizeof(protocol.packet)
return protocol
@/lua/common/libs/lua-websockets/websocket/tools.lua
-- necessary on sizeof(int) == 32 machines
h0 = band(h0,0xffffffff)
@/lua/ge/extensions/tech/capturePlayer.lua
local function radarReturnsToPointcloud(sensorData)
local returnSize = ffi.sizeof('struct radar_return_t')
local points = #sensorData / returnSize
pcd:addField('z', 4, 'float')
local points = #response.data / ffi.sizeof('struct radar_return_t')
pcd:setData(pointcloud, points * ffi.sizeof('struct __luaVec3_t'))
local points = #response.data / ffi.sizeof('struct radar_return_t')
pcd:setData(pointcloud, points * ffi.sizeof('struct __luaVec3_t'))
@/lua/common/extensions/ui/imgui_gen_luaintf.lua
if ImVec2_graph_size == nil then ImVec2_graph_size = ImVec2(0,0) end
if int_stride == nil then int_stride = ffi.sizeof('float') end
if string_label == nil then log("E", "", "Parameter 'string_label' of function 'PlotLines1' cannot be nil, as the c type is 'const char *'") ; return end
if ImVec2_graph_size == nil then ImVec2_graph_size = ImVec2(0,0) end
if int_stride == nil then int_stride = ffi.sizeof('float') end
if string_label == nil then log("E", "", "Parameter 'string_label' of function 'PlotHistogram1' cannot be nil, as the c type is 'const char *'") ; return end
@/lua/common/tcpServer.lua
]]
local headerSize = ffi.sizeof("message_header_t")
local header = ffi.new("message_header_t")
ffi.copy(header, buffer, ffi.sizeof("message_header_t"))
@/lua/ge/extensions/editor/api/gui.lua
end
if int_stride == nil then int_stride = ffi.sizeof('float') end
imgui.PlotLines1(string_label, float_values, int_values_count, int_values_offset, string_overlay_text, float_scale_min, float_scale_max, ImVec2_graph_size, int_stride)
@/lua/ge/extensions/core/remoteController.lua
-- notice the reverse - for the network endian byte order
ffi.copy(orientation, data:reverse(), ffi.sizeof(orientation))
@/lua/common/utils/pixellib.lua
rgbaBuffer:reset()
rgbaBuffer:set(data, ffi.sizeof(data))
if not bitmap:fromBuffer(rgbaBuffer) then
@/lua/common/extensions/ui/imguiUtils.lua
-- print('font 1: ' .. tostring(f))
-- f = f + ffi.sizeof('ImFont') -- second font
-- print('font 2: ' .. tostring(f))