image_storage_slice(3)
π NAME π
okay so this is image_storage_slice(3) from the Arcan Lua API manual, bestie. The NAME line is literally image_storage_slice - with no extra description after the dash β that's the whole vibe. π
β¨ SYNOPSIS β¨
true or false
image_storage_slice( vid:store int:type vidtbl:slices )
πΈ DESCRIPTION πΈ
Some rendering effects need specialised storage layouts that the page calls 'sliced' β the name comes from the fact that they represent slices of some geometry. The typical layouts are 'cubemaps' (SLICE_CUBEMAP) and '3D' textures (SLICE_ 3D). This is not normally supported by the engine, but the backing store of a video object can irreversibly be converted to those storage formats with this function. It returns true if the backing store was successfully converted. That property then carries through when you use image_sharestorage. π¦
Calling the function multiple times with the same input set will update the slices that have a more recent upload timestamp than the previous slice in the corresponding slot. The performance characteristics of this function also vary with the underlying hardware platform, the source format of the individual slices, and the GPU affinity of the individual slices. The default and typically worst case requires a full GPU -> CPU -> GPU synchronous transfer, so it's not suitable for high rate updates. No cap. π
π NOTES π
- The number of slices and the current backing store of
storeshould have a power-of-two base width (height will be ignored).
π§ EXAMPLE π§
function image_storage_slice0()
local surf = alloc_surface(32, 32)
local c1 = fill_surface(32, 32, 255, 0, 0)
local c2 = fill_surface(32, 32, 255, 255, 0)
local c3 = fill_surface(32, 32, 255, 0, 255)
local c4 = fill_surface(32, 32, 255, 255, 255)
local c5 = fill_surface(32, 32, 0, 255, 0)
local c6 = fill_surface(32, 32, 0, 0, 255)
image_storage_slice(surf, SLICE_CUBEMAP, {c1,c2,c3,c4,c5,c6})
end
π SEE ALSO: π
Go check out image too β that's the SEE ALSO reference, bestie. π«Ά
Footer sign-off: source/version image, date October 2026 β stay slay, and remember that conversion is irreversible π
β¨
π¦ where this page comes from
- nixos 26.05: arcan 0.7.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms