Sarbian changed the topic of #kspmodding to: Welcome to #kspmodding - the channel for discussing, and learning about, modding Kerbal Space Program. Code of Conduct: https://git.io/vSQh6 | Always provide logs. | *** PSA: https://kerbalspaceprogram.com/api/index.htm | Someone is writting a Phd dissertation on KSP modding please fill out this survey https://goo.gl/forms/1vrkPYH4az8l32sb2 - I have met him and it s legit
_whitelogger has joined #kspmodding
<taniwha>
xShadowx: summation of the volumes of the tetrahedrons formed by each tiangle and the origin
<xShadowx>
taniwha: thats blender's way?
<taniwha>
afaik, it's the only way
<xShadowx>
from googling, thats the fast/simple way, but only works on simpler objects like cube/sphere, where no tetraheda cross as they connect to the origin
<taniwha>
no, it works no matter what shape the object is
<taniwha>
just so long as it is /closed/
<xShadowx>
the more expensive / slow way, is voxelize it, which is uber slow, but works for concave objects, such as humanoids, and horseshoes
<xShadowx>
er
<taniwha>
tetrahedrons works just fine for manifold objects
<taniwha>
concave vs convex is irrelevant
<xShadowx>
i made a cube in blender, got the vertex coords, math off website o calc volume, worked as expected, but then i divided 1 fce, moving the center vert to the oposite face, essentially making a square vase kinda shape, ran same math, and got an incorrect value
<xShadowx>
while blender math is correct but no ideda the algorithm used :|
<taniwha>
that's because of two reasons
<taniwha>
1) blender's math is not quite as accurate as it should be
<taniwha>
2) the cube is not quite as accurate as it should be
<xShadowx>
2) cube was perfect ;p polygons just intersected
<taniwha>
er, and maybe 3) it sounds like you did something really weird
<taniwha>
cube is NOT perfect
<taniwha>
it is not +/- 1.0 on all axes
<xShadowx>
the one i made was ;\
<taniwha>
but rather 0.999999 and 1.000002 or something like that
<xShadowx>
b/c floating point?
<taniwha>
because of how the cube is created
<taniwha>
it's a cylinder in disguise ;)
<xShadowx>
when i selected verts, shows +/- 1 as coords
<SilverFox>
wait up
<xShadowx>
and volume checks out as 8 ;\
<SilverFox>
a cube is a cylinder in disguise?
<xShadowx>
yep ;p
<xShadowx>
taniwha: anywho, so you're saying the tetrahra method should work fine on a humanoid shape?
<xShadowx>
mesh is closed
<xShadowx>
atleast best i can tell ;p
<xShadowx>
tetrahedra*
<taniwha>
yes, it will
<taniwha>
but the mesh MUST be closed
<xShadowx>
i tried the voxel way to calc and it was quite a bit slower ;\ so hoping to avoid that
<taniwha>
and I just checked: blender does the right thing for my cubical cup
<taniwha>
default cube, inset one face by 0.1, extrude it by -1.9
<taniwha>
volume is 1.844
<xShadowx>
oh i know blender is right, atleat using the volume from the 3d print tools
<taniwha>
this is correct for 2**3-1.8**2*1.9
<SilverFox>
taniwha, how the fuck you make a cube outta cylinder?
<xShadowx>
i was saying the tetrahedra math was showing incorrect (no idea which method blender is using)
<xShadowx>
you forget a mesh needs triangles for its faces, to say what verts connect to what
<taniwha>
they're ints
<taniwha>
12 bytes per face
<taniwha>
and most verts will be shared
<xShadowx>
its still list 3 verts per face
<taniwha>
yes, but using vertex indices
<xShadowx>
1mil faces
<taniwha>
thus 3 ints per face
<xShadowx>
yep
<xShadowx>
so 12mb there
<taniwha>
but for a closed surface, your vertex and face count will be close
<taniwha>
so 24MB
<xShadowx>
then the normals, vector3, another 12mb
<taniwha>
yeah
<taniwha>
UVs another 8MB
<xShadowx>
so 36mb
<xShadowx>
44mb
<taniwha>
still not going to hit 10GB
<xShadowx>
funny thing is i loaded 1mil poly version into unity, took a couple seconds to read it all
<taniwha>
also, 500 morphs seems excessive
<xShadowx>
4mil version, it craps out for 2 hr lol
<xShadowx>
that 500 morphs only moves the verts that move
<taniwha>
oh, last I heard, unity uses shorts (16 bits) for indices, not ints (32 bits)
<xShadowx>
so no junk data
<xShadowx>
idk o.o
<xShadowx>
i just know it works ;p
<taniwha>
still, you sure it's morphs and not bones?
<xShadowx>
yep
<xShadowx>
b/c i have to export a 1mil poly obj for every morph target lol no bones included
<taniwha>
and... humanoid models are never 1Mpoly for games
<xShadowx>
ya funny thing
<taniwha>
low-poly versions are used
<xShadowx>
i always heard 2-5k
<taniwha>
(with texture baking and the like)
<xShadowx>
i goto the game markets, models are 2-5k
<Rokker>
reeeeeeeee stop pinging me
<xShadowx>
i look a unity, im running 90fps on a 4k mesh
<xShadowx>
so i get the idea
<taniwha>
the 1Mpoly models are used for baking normal maps etc into the low-poly models
<Rokker>
reeee
<SilverFox>
Rokker, why ping?
<xShadowx>
goto an old market i used to use for 3d animation / stills
<xShadowx>
i got a nice 1mil poly model thats uh.......detailed
<Rokker>
poly pings me
<xShadowx>
best part, universal base mesh
<taniwha>
xShadowx: that's not a production model
<taniwha>
that's a pre-production model
<SilverFox>
why
<taniwha>
used for baking
<xShadowx>
the site sells 'characters' as morphs for the base mesh'
<taniwha>
becaus Rokker wants crackers
Rokker has left #kspmodding [#kspmodding]
<xShadowx>
no
Rokker has joined #kspmodding
<Rokker>
reee
Rokker has left #kspmodding [#kspmodding]
<xShadowx>
thats a model used for high detail for 3d art
Rokker has joined #kspmodding
<taniwha>
same thing
<xShadowx>
so i loaded the 1mil poly char
<Rokker>
its because I moderate a channel that bans politics and they tried using poly ticks to hide it from me
<xShadowx>
unity running 90 fps still
<Rokker>
SilverFox: ^
Rokker has left #kspmodding [#kspmodding]
<taniwha>
xShadowx: because it's been moved to your GPU
<xShadowx>
i havent tried between 1 and 4 mil poly though as said 4mil craps out, and getting between there isnt much of an option for that universal mesh
<xShadowx>
indeed ;p
<xShadowx>
so morale of the story is 1mil poly works just fine for m,e ^.^
<SilverFox>
lmao
<taniwha>
xShadowx: your GPU probably doesn't have enough memory
<taniwha>
(I suspect might might not, but my CPU does)
<taniwha>
xShadowx: but you're not doing anything with the model
ferram4__ has joined #kspmodding
<taniwha>
er, I suspect my GPU might not
<taniwha>
64GB system memory
<taniwha>
not sure how much GPU memory
<xShadowx>
thats with the model moving and walking and jumping
<xShadowx>
i got 64gb system, 8gb gpu
<taniwha>
8GB
<xShadowx>
well....128gb system, but 64 is 'system' and 64 'ramdisk'
<taniwha>
my MB capped out at 64
<xShadowx>
ssd slow :|
<taniwha>
yes, ssd is slow
<xShadowx>
mine capped 128 lol
<taniwha>
not worth the money, imo
<taniwha>
you got yours more recently than I got mine
<xShadowx>
ram was cheap when i got it
<taniwha>
(mine's about 2yo now)
<xShadowx>
mine 2 yr too
<xShadowx>
well
<xShadowx>
2yr in 3 months
<xShadowx>
got it at black friday
ferram4_ has quit [Ping timeout: 183 seconds]
<xShadowx>
or black week......now black november
<taniwha>
hmm
<taniwha>
wonder how long mine was sitting on the shelp
<taniwha>
...
<xShadowx>
but ya ram wasnt that bad
<taniwha>
shelf
<xShadowx>
i dont even know how long mine was out either
<xShadowx>
i just went for core i7, found parts, done ;p
<taniwha>
yeah
<xShadowx>
taniwha: and read priv :)
<xShadowx>
from googling, does mention a 65k limit on polys for stuff, that must be for the 16 bit indices
<xShadowx>
yet 1mil poly works, so maybe its adjusting to 32bit indices?
<xShadowx>
still 12+12+12+8=44mb for 1mil vert/poly/normal/uv
<xShadowx>
gpu is 8gb......shouldnt i be able to go higher? ramwise anyways
<xShadowx>
that 44mb seems tiny ;\
<taniwha>
22GB at 500 morphs
<xShadowx>
not all verts are used every moprph
<taniwha>
not all verts are /moved/
<xShadowx>
average prolly 10% ish random guess
<xShadowx>
ya, unmoved arent stored
<taniwha>
don't count on it
<xShadowx>
? i loaded them, i know they arent o.O
<taniwha>
your verts are considered innocent of pruning until proven guilty :P
<xShadowx>
the data isnt there
<xShadowx>
lol
<xShadowx>
anywho, even ignoring the morphs, 44mb seems tiny
<xShadowx>
but 4mil poly killed unity -.-
<taniwha>
yes, 0.044bits is tiny
<xShadowx>
i gotta see how much unity accually uses up loading that
<xShadowx>
shush ;p
<SilverFox>
how do you have <1 bit?
<xShadowx>
538Mb for unity when no model, 3,475Mb with model used once, 2nd copy no addition gain as expected
<taniwha>
SilverFox: makes sense when it's bits/something
<xShadowx>
so 2,937Mb used for 1mil poly.......why isnt it 44Mb
<SilverFox>
potentially
<taniwha>
eg, 0.044bits/second
<taniwha>
22.7s to transmit a bit
<taniwha>
sounds like some satellite data services :P
* xShadowx
lights taniwha's chair on fire
<xShadowx>
gpu ram gets about the same usage spike
<xShadowx>
so whys it eating mah ram and not using 44Mb
<SilverFox>
yeah
<SilverFox>
or a super-encrypted stream
<xShadowx>
no morphs loaded, just base mesh, no bones, no materials assigned
<xShadowx>
wth >.>
<xShadowx>
i mean it runs fine.....not the point
<xShadowx>
just where dafuq my ram ;p
<SilverFox>
~wa 466.59 + 66.19 USD to CAD (nocache)
<SilverFox>
damnit
<xShadowx>
!wa 1 USD to CAD
<xShadowx>
aw
<xShadowx>
bot died?
<xShadowx>
wait what was qboid again >.>
<xShadowx>
!wa usd to cad
<Qboid>
xShadowx: convert $1 (US dollar) to Canadian dollars: C$1.28 (Canadian dollars)
<xShadowx>
then why no worky when 1......
* xShadowx
kicks Qboid
_whitelogger has joined #kspmodding
_whitelogger has joined #kspmodding
ferram4__ has quit [Read error: Connection reset by peer]
ferram4 has joined #kspmodding
ferram4 has quit [Read error: Connection reset by peer]
ferram4 has joined #kspmodding
_whitelogger has joined #kspmodding
oeuf has joined #kspmodding
VanDisaster has quit [Ping timeout: 202 seconds]
egg has quit [Ping timeout: 202 seconds]
_whitelogger has joined #kspmodding
_whitelogger has joined #kspmodding
_whitelogger has joined #kspmodding
hashashin has joined #kspmodding
egg has joined #kspmodding
oeuf has quit [Ping timeout: 200 seconds]
Lyneira has joined #kspmodding
VanDisaster has joined #kspmodding
hashashin has quit [Read error: Connection reset by peer]
hashashin has joined #kspmodding
hashashin has quit [Ping timeout: 200 seconds]
Ezriilc has joined #kspmodding
hashashin has joined #kspmodding
VanDisaster has quit [Quit: Miranda NG! Smaller, Faster, Easier. http://miranda-ng.org/]
VanDisaster has joined #kspmodding
hashashin has quit [Ping timeout: 200 seconds]
Lyneira has quit [Quit: Bye]
<xShadowx>
taniwha: reading more, looks like what the volume calc is doing, if using vector functions, vol = v1.Dot(v2.Cross(v3)) / 6.0f; i think?
<xShadowx>
then your function was doing is drop the /6.0f, just store all the values, sort at end, sum, and a single /6.0f?