offsetof
Definition
-- @/=[C]:-1
function offsetof(...)
Callers
@/lua/ge/extensions/tech/pythonExport.lua
end
if type(value) == 'cdata' and ffi.offsetof(value, 'z') ~= nil then -- vec3
if ffi.offsetof(value, 'w') ~= nil then -- quat
if type(value) == 'cdata' and ffi.offsetof(value, 'z') ~= nil then -- vec3
if ffi.offsetof(value, 'w') ~= nil then -- quat
return string.format('(%.4g, %.4g, %.4g, %.4g)', value.x, value.y, value.z, value.w)
@/lua/common/jbeamWriter.lua
if vtype == 'cdata' and ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then
if vtype == 'cdata' and ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then
return stringformat('{"x":%.10g,"y":%.10g,"z":%.10g,"w":%.10g}', v.x, v.y, v.z, v.w)
@/lua/common/lpack.lua
cdata = function(v)
if ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then -- quat
if ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then -- quat
bufTmp:put(tostring(v))
cdata = function(buf, v)
if ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then -- quat
if ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then -- quat
buf:put("\0\251"):encode(v.x):encode(v.y):encode(v.z):encode(v.w)
cdata = function(v, seridx)
if ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then -- quat
if ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then -- quat
serTmp[seridx] = '&'
@/lua/common/libs/lua-MessagePack/MessagePack.lua
packers['cdata'] = function(v)
if ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then -- quat
if ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then -- quat
bufTmp:put(char(0x84))
@/lua/common/jsonPrettyEncoderCustom.lua
if vtype == 'cdata' and ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then
if vtype == 'cdata' and ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then
return string.format('{"x":%.10g,"y":%.10g,"z":%.10g,"w":%.10g}', v.x, v.y, v.z, v.w)
@/lua/common/utils.lua
bufTmp:put(tostring(v))
elseif vtype == 'cdata' and ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then
elseif vtype == 'cdata' and ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then
bufTmp:putf('{"x":%.10g,"y":%.10g,"z":%.10g,"w":%.10g}', v.x, v.y, v.z, v.w)
if vtype == 'cdata' and ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then
if vtype == 'cdata' and ffi.offsetof(v, 'z') ~= nil then -- vec3
if ffi.offsetof(v, 'w') ~= nil then
return stringformat('{"x":%.10g,"y":%.10g,"z":%.10g,"w":%.10g}', v.x, v.y, v.z, v.w)