Search
9:16:15
Shinmera
|3b|: any advice on how to use glsl-packing? For some reason pack-structs returns NIL for me. https://plaster.tymoon.eu/view/1460#1460
9:16:16
Colleen
plaster.tymoon.eu/view/1460... Website (XHTML), Title: - Plaster
9:16:22
Shinmera
trying to use it to verify my own packer
9:16:56
|3b|
let me look at it for a bit
9:18:22
Shinmera
do the vec member types need to be (:float 32) instead of :float?
9:19:40
|3b|
looks like it might want a name for struct, so ((:packing :std140) ("struct1" (:struct () ...)))
9:20:00
|3b|
and also bit sizes for float types
9:20:41
Shinmera
Even with those changes I still get NIL
9:21:16
|3b|
does it have the packing-test* files in the repo?
9:22:21
|3b|
load packing-test2.lisp, then run (packing-test2::gen-structs) to see some example struct defs
9:23:25
Shinmera
that errors with "package glsl-packing-io does not exist"
9:24:24
Shinmera
(and loading that file gives another warning)
9:25:08
|3b|
ah, just C-c C-c the forms up to gen-structs (or wait a bit while i copy example output into a "write a readme" issue)
9:25:33
Shinmera
Yeah I got it. Looking at the example output, this should work: https://plaster.tymoon.eu/view/1460#1461
9:25:33
Colleen
plaster.tymoon.eu/view/1460... Website (XHTML), Title: - Plaster
9:25:41
Shinmera
but I still get NIL
9:28:38
|3b|
ah, i think you also need a block
9:29:02
|3b|
since matrix order is per block state or something like that
9:29:27
|3b|
though then it complains about not being able to store anonymous structs in an array :/
9:30:07
Shinmera
Right, so I guess I need to unroll the inner struct?
9:30:23
|3b|
is that something valid to do in glsl?
9:30:50
Shinmera
you mean nesting the struct def?
9:31:39
Shinmera
alright, this flushes. https://plaster.tymoon.eu/view/1460#1462
9:31:39
Colleen
plaster.tymoon.eu/view/1460... Website (XHTML), Title: - Plaster
9:32:07
Shinmera
do you know an easy way to unroll all the uniform fields from there including their absolute offset?
9:33:11
Shinmera
Something like https://filebox.tymoon.eu//file/TVRjMU9RPT0=
9:33:11
Colleen
filebox.tymoon.eu//file/TVR... Image (PNG)
9:34:28
Shinmera
(the above is what I'm trying to verify)