IRC logs of Libera.Chat #BZFlag for Sunday, 2021-06-20

*** DTRemenak <DTRemenak!~DTRemenak@2603-8001-3700-003f-f089-b02e-2975-0f3d.res6.spectrum.com> has quit IRC (Ping timeout: 264 seconds)00:02
*** DTRemenak <DTRemenak!~DTRemenak@2603-8001-3700-003f-2467-8e07-0bbc-2679.res6.spectrum.com> has joined #bzflag02:11
*** bryjen <bryjen!~bryjen@2603-6010-7a04-7681-0ad4-0cff-fe30-0e67.res6.spectrum.com> has joined #bzflag05:05
*** bryjen <bryjen!~bryjen@2603-6010-7a04-7681-0ad4-0cff-fe30-0e67.res6.spectrum.com> has quit IRC (Quit: Leaving)07:03
*** Sgeo <Sgeo!~Sgeo@user/sgeo> has quit IRC (Read error: Connection reset by peer)09:24
blast007I'm working on exporting our tank model and have it mostly working, but there's some face or normal issues that I'm unclear on the correct fix.13:29
blast007In Blender the textures look right, but some faces are darker, indicating that the normal is flipped.  In Wings3D, the shading looks right, but the texture on some faces are flipped/rotated.13:30
blast007That may just be a difference between how Blender and Wings3D handle drawing flipped normals.13:31
blast007would anyone be able to help with this?  https://github.com/blast007/bzflag-model-writer/issues/113:31
blast007heh... and of course after writing all that out, I think I found the fix.. If I alternate the order of the vertices for each triangle in a GL_TRIANGLE_STRIP it looks right.13:38
*** GEP <GEP!~GEP@2607:fb90:9834:3734:981c:10f2:86f7:b640> has joined #bzflag13:43
*** GEP <GEP!~GEP@2607:fb90:9834:3734:981c:10f2:86f7:b640> has left #bzflag13:53
the_mapordering of corners for normal direction sounds familiar14:07
the_maphttps://stackoverflow.com/a/814246114:09
the_map"By default, counterclockwise polygons are taken to be front-facing." and "You can change which way OpenGL considers "front facing" via glFrontFace()"14:10
blast007https://static.bzexcess.com/misc_screenshots/tank-model-blender-final.png14:13
blast007(that's using an 8x "AI" upscaled version of our normal tank texture and the tread texture from 2.6)14:14
the_mapnaming something "final" is an almost guaranteed way to notice something's slightly off :p14:14
blast007nah, it's cool, Final Fantasy does it14:14
the_mapthat tank looks very round14:14
the_mapare the tanks that round? I haven't played in a bit14:14
the_mapit looks great though14:15
the_mapone thing I'd request is paneling the texture instead of scaling14:15
blast007the lighting or shading in Blender might be better than in-game14:16
blast007the muzzle looks more brown in-game too, though I'm not sure why14:17
the_mapit's been in the field, it got dirty14:17
blast007:P14:18
the_mapis it possible the barrel is inside-out? ie, such that the normals are on the inside14:22
blast007no, the color of the barrel in the code is gray14:27
blast007or do you mean in-game?14:28
the_mapnah I meant in your GL code14:28
the_mapbe funny if the game had a bug there though that you found by doing this14:29
blast007https://github.com/BZFlag-Dev/bzflag/blob/2.4/src/geometry/TankSceneNode.cxx#L1280-L128414:29
JeffM[m]blast007: yeah strips toggle order17:45
*** I_Died_Once <I_Died_Once!~I_Died_On@c-73-184-170-223.hsd1.ga.comcast.net> has joined #bzflag18:32
*** bryjen <bryjen!~bryjen@2603-6010-7a04-7681-0ad4-0cff-fe30-0e67.res6.spectrum.com> has joined #bzflag18:35
*** Okina <Okina!~Yukari@user/yukari> has joined #bzflag18:43
*** Sgeo <Sgeo!~Sgeo@user/sgeo> has joined #bzflag19:08
*** hop <hop!~hop@nl48.30hopsmax.at> has left #bzflag19:13
JeffM[m]blast007, IIRC the barrel is gray in code, but it uses the last set of UV cords loaded, so it blends it with the texture color, so it will be tinted some color. Whatever texel was at the last loaded UV since it doesn't disable textures for that part.20:02
JeffM[m]barrel is always done after turret, so the last UV in the turret would be 0.766f, 0.326f, so that's probably what is used for the barrel20:10
*** bryjen <bryjen!~bryjen@2603-6010-7a04-7681-0ad4-0cff-fe30-0e67.res6.spectrum.com> has quit IRC (Quit: Leaving)20:19
*** bryjen <bryjen!~bryjen@cpe-74-140-75-218.columbus.res.rr.com> has joined #bzflag20:30
AgathaIs this a good time to harp on the tank model's hardcoding as being a deficiency? If possible, can we clean it up and load as a ".obj" or something?20:37
JeffM[m]that was always the plan20:38
JeffM[m]someone just needs to write the code20:38
JeffM[m]or finish writing the code20:38
AgathaIs there a model loader for a standard format in the source? What format?20:39
AgathaErr hmmm, doesn't the world support .obj loaded objects?20:39
JeffM[m]there is not20:39
JeffM[m]nope20:39
JeffM[m]obj is ok, it's wordy and text based20:43
JeffM[m]best would be to compile the model into a runtime resource20:43
JeffM[m]and read that20:43
JeffM[m]then you can store metadata, like the pivot points20:43
JeffM[m]and attachments for the parts20:43
JeffM[m]the tank isn't just one model, it's a collection of parts, for moving wheels and explosions.20:43
JeffM[m]you should start by looking at TankGeometryMgr.h20:47
OkinaWhile on the subject of the tank model, should we consider possible updates on the detailing of the models?20:50
JeffM[m]you should make it external first20:51
JeffM[m]it's hardcoded right now, so any changes would have to be made in C20:51
JeffM[m]not a tool like blender20:51
JeffM[m]one it's external, you can let people use any model they want :)20:51
OkinaTrue. Although my main thoughts are more of should there be quality on the tank models, similar to the current graphics quality settings.20:52
OkinaThus we have high detailed models, mid detailed and low detailed models.20:53
JeffM[m]bzflag already supports that. there are 3 levels of detail. hitank, medtank, and lowtank20:53
JeffM[m]another reason to use a resource format, you can pack in LOD versions of all the parts.20:54
JeffM[m]They are all just VERY low detailed20:55
JeffM[m]for modern standards20:56
JeffM[m]the TankGeometryMgr has code to provide the requested LOD, and different quality levels limit the LOD type.20:58
JeffM[m]once it returned data from an external source then it'd just keep working like that.20:59
*** bryjen <bryjen!~bryjen@cpe-74-140-75-218.columbus.res.rr.com> has quit IRC (Quit: leaving)20:59
JeffM[m]it just needs to be finished up21:04
blast007I have all the tank models (normal, obese, tiny, thief tiny, and narrow) as .obj now.21:34
JeffM[m]nice21:35
blast007though it wouldn't have animations, but it's the first step to getting it into a format that could do that21:35
blast007obj was easy to write to21:35
JeffM[m]that's the point of it :)21:35
JeffM[m]you may want to look at GLTF21:35
blast007couldn't find a C/C++ library that could write GLTF, for instace21:35
blast007plenty of loaders though21:36
JeffM[m]yeah, not sure if I've ever seen a writer21:36
blast007GLTF might also work as a map format, but we'd either need to bundle some extra data file for our custom features (such as teleporters) or write our own extension21:37
blast007Blender supports plugins that add extensions to their GLTF importer/exporter21:38
JeffM[m]yeah GLTF is kind of just a container format, you can shove all kinds of stuff into it21:38
*** I_Died_Once <I_Died_Once!~I_Died_On@c-73-184-170-223.hsd1.ga.comcast.net> has quit IRC (Ping timeout: 265 seconds)23:40
*** I_Died_Once <I_Died_Once!~I_Died_On@c-73-184-170-223.hsd1.ga.comcast.net> has joined #bzflag23:58

Generated by irclog2html.py 2.17.3.dev0 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!