Time Nick Message 00:07 MTDiscord Not that it hasn't been requested and shot down already multiple times 00:10 MTDiscord But if, I'd love to see it happen ? 00:21 v-rob To actually make sending the screen size useful, you'd also have to know about font dimensions, really, which is difficult from a technical standpoint 00:22 v-rob I can see DPI and aspect ratio being useful without anything else, but screen size really needs font dimensions to be useful 00:23 MTDiscord Barging in to let you all know, I'm still looking for a second approval on my IRRLICHTMT_BUILD_DIR PR. Barging back out. 00:23 MTDiscord you should link it 00:24 MTDiscord #11656 00:24 ShadowBot https://github.com/minetest/minetest/issues/11656 -- Add variable to use existing IrrlichtMt build by JosiahWI 00:26 v-rob It wouldn't be very nice to expose that info anyway because it would be expecting modders to take into account screen size, DPI, GUI scaling factor, and font dimensions. 00:26 v-rob I guess DPI + GUI scaling could be abstracted into some sort of abstract pixel, but that'd probably make people unhappy still. 00:27 MTDiscord no 00:27 MTDiscord just give us the full information 00:28 MTDiscord we can already do lots with screen percentages 00:28 MTDiscord knowing exactly the size of the screen would allow us to provide properly shaped formspecs for even stranger devices 00:28 MTDiscord let mods actually handle the problem rather than shoehorning a completely fucking terrible solution to the problem 00:28 MTDiscord are you developing a game or game engine 00:29 MTDiscord >expecting modders to take into account screen size, DPI, GUI scaling factor, and font dimensions 00:29 MTDiscord that is literally what modders want 00:30 MTDiscord ^ 00:30 MTDiscord or better yet, we could build fully working games with the HUD API given the screen information 00:30 MTDiscord see https://content.minetest.net/packages/luk3yx/prang/ for more details 00:32 MTDiscord hell how can we even dare call minetest a game engine let alone it lacks the usual facilities to even create the most minimal of 2D or even 3D games 00:36 MTDiscord hell why are we even debating the need of this 00:36 MTDiscord browsers send it without question to relative javascript APIs and there's no issue there 00:37 MTDiscord but god forbid it makes lives easier for mod/game devs 00:37 v-rob But browsers mainly use CSS for layouting. 00:37 MTDiscord get a load of web 1.0 over here 00:40 v-rob To actually make it easy for game devs, we'd have sizers built into the GUI. I feel split because the right way to do it is to make sizers actually built into the GUI, but formspecs have no such thing. However, I don't want modders being forced to do manual absolute positioning calculations be the norm. 00:42 v-rob In other words, I don't want to set the workarounds in concrete and make them the solution 00:43 MTDiscord just leave it to mod developers to build their own libraries around the problem 00:43 v-rob Yeah, I know 00:43 MTDiscord stop dictating what mod/game devs need because without absolute control and precision i may as well write it in god forbid, unreal 00:43 v-rob I just want the engine to be doing it so the modders don't have to. Ugh 00:44 MTDiscord you need to stop handholding people, the faster they get the stick rather than the carrot the better 00:44 MTDiscord as much as i dislike saying this, the hypertext formspec element is far more useful than any of the existing versionings has ever done 00:45 MTDiscord I think you may be running into the difference between "don't have to" and "are unable to". Having simpler solutions doesn't preclude exposing information for custom lower-level solutions 00:45 MTDiscord In fact, I think having both is ideal 00:45 MTDiscord ^this 00:46 v-rob I mean, that does make sense 00:46 v-rob There is, of course, the technical aspect as well 00:46 v-rob Fonts are particularly problematic 00:46 MTDiscord boxing users and ostensibly the developers you're trying to attract with a limited viewpoint is extremely bad for business 00:47 MTDiscord if a mod begins to require engine changes to do any form of heavy lifting it's automatically a failure 00:47 MTDiscord vrob: dont box yourself into not given x because of y, y can always be done later, but x can be used without y in multiple ways typically 00:49 MTDiscord we're complaining simply because we see a very major problem in why it's a very bad idea 00:49 MTDiscord let them have cake, and eat it, too 00:50 v-rob OK then, presume we are planning on adding client info then. Sending window sizes is easy (it changes rarely, so a callback is possible, like `minetest.register_on_window_resize`), as is DPI and GUI scaling. How could one get font info then? 00:51 MTDiscord pretty sure calculating pt based on DPI is super simple 00:52 MTDiscord most character glyphs range from about a 1:1.5 to 1:2.5 ratio 00:52 rubenwardy If the window changes screens, the DPI may change 00:52 rubenwardy And the window size may change at any time 00:52 rubenwardy So that's something you'd need to take into account 00:52 v-rob That would be the idea of a callback, not a static field 00:52 MTDiscord system dpi != monitor display size 00:53 rubenwardy DPI is per screen 00:53 MTDiscord maybe per screen but even 1440p (WQHD) is 97dpi 00:53 MTDiscord 96* 00:53 v-rob Some laptops nowadays are preeeeety high DPI, even if external screens connected to them are not. 00:54 MTDiscord DPI is only a measurement of how far is a physical inch 00:54 MTDiscord if anything depending on a user configurable value in minetest.conf is very dumb 00:55 v-rob Still, a callback would mitigate the issue. Or, `player:get_window_info()` where the client sends window info to the server whenever it changes. It's not really insurmountable at all. 00:55 MTDiscord saying that we need a major talk about networking 00:56 MTDiscord serious business discussion going forwards because it's a total fucking mess 00:56 rubenwardy It doesn't really solve this particular issue though, as there's no good way to find out how big text will be 00:56 MTDiscord considering the default font we use is a practical known quantity that shouldn't be difficult 00:56 rubenwardy It would help, along with touchscreen info, with switching between touch friendly and desktop UIs 00:57 v-rob I don't know anything about the networking code, but it would just be a client->server message whenever screen info changes, and the server stores that info 00:57 MTDiscord basically for any feature that communicates either way you spend one packet of 255 afaik 00:57 MTDiscord 255 total unique enums 00:57 v-rob Fonts, though, are completely unreliable. Font height is probably easy enough to calculate, but there's no way in the world to query the font width 00:58 v-rob E.g. a hypertext is nigh impossible from the server without it 00:58 MTDiscord instead of complaining about fonts just give us the option to use a bounding box 00:58 MTDiscord defined the exact same way for positioning we do now 00:59 v-rob Although, servers should 100% not implement their own hypertexts. I don't care how much we should give to the modders, they will never support Unicode properly. 00:59 erlehmann just give us the full information 00:59 v-rob I know we don't (yet), but modders never will. 00:59 erlehmann Jordach great then i can finally get servers who will exclude me based on screen size 00:59 erlehmann and i have to make a hacked client 00:59 erlehmann to access them 00:59 MTDiscord it's more the operator won't care 00:59 MTDiscord https://store.steampowered.com/hwsurvey/Steam-Hardware-Software-Survey-Welcome-to-Steam 00:59 MTDiscord see this? 01:00 erlehmann LVDS1 connected primary 1400x1050+0+0 (normal left inverted right x axis y axis) 290mm x 210mm 01:00 MTDiscord if you click primary display resolution, it'll show you the exact percentage of the many millions of steam users 01:00 erlehmann oh you are THAT kind of person 01:00 MTDiscord 1400x1050 sounds exactly like a 19:10 display 01:01 erlehmann uh what 01:01 erlehmann it's 4:3 01:01 erlehmann approx 01:01 MTDiscord point is we can gather aspect from calcuating w/h so it's not an issue 01:02 erlehmann like how do you even get to 16:10 01:02 MTDiscord because it's one of those wack resolutions 01:02 erlehmann i think you fail at division forever 01:03 erlehmann ; printf '4 k 1400 1050 / p 4 3 / p' |dc 01:03 erlehmann 1.3333 01:03 erlehmann 1.3333 01:03 erlehmann all clear? :D 01:03 MTDiscord i've got no problem with 4:3, 16:10 or the wack as fuck mobile users 01:04 erlehmann Jordach i have done CSS layouts that worked for mobile and desktop and the most important lesson i have learned is it is a bad idea to give the server too much control 01:04 erlehmann what is good is to have constraint-based layout and breakpoints 01:04 erlehmann but what is bad is sending exact resolution etc. 01:04 MTDiscord it's not our job to police everything a user does like some kind of stasi 01:05 MTDiscord we leave that to the mod/game dev to taste 01:05 erlehmann no no it is about API design 01:05 erlehmann good API design makes entire classes of fuckups impossible 01:05 MTDiscord canvas.js and Phaser; two notable things hard depend on that 01:05 erlehmann for example, user agents. bad API design. 01:05 erlehmann you can see it bc clients start to lie. 01:05 erlehmann content negotiation? good API design. no reason to lie. 01:06 erlehmann minetest ideally should not repeat problems the web has 01:07 MTDiscord the real problem is not allowing regular users to make an absolute mess on their own 01:07 MTDiscord giving them a free out is extremely bad 01:08 erlehmann Jordach actually pretty much everyone i have seen who uses javascript on websites to do layout or animation instead of CSS or SVG is getting it horribly wrong 01:08 v-rob If we're criticizing API design, formspecs are about the worst possible API ever in the history of GUIs 01:08 erlehmann v-rob yeah but you can make them worse 01:08 MTDiscord see every MTG fork that aims to fix it and ends up becoming some amalgam of forum mods 01:09 erlehmann i am actually pretty happy that the engine devs do not give in to clowns who want the server to send every detail about the client to the server 01:09 erlehmann i mean who want the client to send it 01:09 erlehmann it is a great show of foresight 01:09 MTDiscord so then why the hell are you using any browser 01:09 MTDiscord it does that by default 01:09 MTDiscord hell even your regular desktop does this with apps and it's DE 01:10 erlehmann i am a hypocrite, society is broken and yet i participate in it! 01:10 erlehmann actually, no. wayland does not allow a bunch of things. 01:10 erlehmann that you can do with X11 01:10 erlehmann and it follows from their API design that you can not do them anymore in wayland 01:11 erlehmann i think an app window can, for example, not absolutely position itself 01:11 erlehmann (i may be wrong on this, can't test it right now) 01:12 erlehmann Jordach i believe one has to talk about what you want to achieve. CSS-like constraint based layout is actually a good way to not send data to the server. 01:12 MTDiscord a window should only choose positions where it's most logical to place it (ie where the mouse pointer resides on a screen, or predefined display) 01:12 MTDiscord CSS works until you find yourself arguing with how shit it truly is 01:12 MTDiscord there's a reason adobe flash isn't dead 01:12 erlehmann i use tiled window managers and object to any windows that place themselves 01:12 MTDiscord because every major game uses it as a HUD 01:12 erlehmann flash is deader than dead tbh 01:13 MTDiscord flash maybe dead but the schema it gave is why most games use it 01:13 MTDiscord https://en.wikipedia.org/wiki/Scaleform_GFx 01:14 erlehmann jordach for some reason *every* person who argued how shitty CSS was was unable to understand the cascade or sibling selectors or other basic stuff. and actually most of them admit it after a short while. 01:14 erlehmann and it is not bc it is complicated too 01:14 erlehmann they are unable because they chose to 01:14 erlehmann i have made complex interfaces in CSS only 01:14 MTDiscord CSS may not be complicated but the assigned box method is absolute ass 01:15 erlehmann but if you want flash-like stuff, use svg, honestly 01:15 erlehmann dvd menus use it i think 01:15 v-rob @media screen and (max-width: 1000px) { * { display: none !important; } #haha { display: block !important; } } (HTML:

Your screen is too small"

) <<<< Yeah, CSS can *definitely* discriminate against you based on screen size. 01:15 MTDiscord something like that is upto the mod/game devs taste 01:15 MTDiscord doing any of that would invite it, sent or not 01:16 erlehmann v-rob it can, of course. but since the client interprets it, you can work around it easier using user stylesheets. 01:16 v-rob But you were just saying that you don't want to workaround it. 01:16 erlehmann yeah so you should not give any way to access raw pixls 01:16 erlehmann rather have landscape/portrait or touch/pointer paradigms 01:16 erlehmann but in a way that one size fits all 01:17 erlehmann i believe one of the best examples for this is GNU emacs. if you do some graphical stuff with it, it will just work in the GTK interface and also in your terminal. 01:17 erlehmann no additional work required 01:17 erlehmann like, i don't know, if you make some elisp that highlights all occurrences of the letter “e” 01:17 MTDiscord if you want to make it just work let mod developers do as they please 01:18 MTDiscord forcing them into a shitty little box that you defined is extremely hostile 01:18 erlehmann actually not 01:18 erlehmann having well-designed APIs and languages makes systems much more powerful in the end 01:18 erlehmann have you read the langsec stuff? 01:19 v-rob erlehmann: I WANT these good APIs you speak of. But they're impossible for formspecs, and the new GUI, even if I worked on it right now every day, it would still take a long time to finish coding, testing, reviewing, and bugfixing it, even in the best case scenario. So modders are stuck with nothing in the meantime. 01:19 erlehmann basically, you need to find out what the complexity of your problem is and then use an approach of exactly that complexity, not more complex (bc then it gets unmaintainable) and not less (but if it is a bit less, you can always add to it later) 01:20 erlehmann v-rob every solution will take a long time. fast, cheap, good – choose max. 2 01:20 v-rob Alternatively, do fast and cheap right now while we work on fast and good. 01:21 erlehmann cheap in this case includes maintainability though 01:21 MTDiscord this is exactly why i suggested just one release a year with the rest of it being bug fixes for up and coming 01:21 erlehmann if you make a too powerful interface, you can never take it away 01:21 v-rob Note: I'm not yet advocating for sending screen size, I still don't know if I support it or am against it yet. I still remain unconvinced either way. 01:21 MTDiscord please see the implementation of PRANG! on CDB 01:22 MTDiscord it's all done with raw HUD API 01:22 erlehmann also if you have a shitty API that is easy to understand or use it will crowd out almost every API that is a bit better 01:22 MTDiscord having known window borders would make it less frustrating 01:24 MTDiscord keeping it simple is far better than the alternatives# 01:24 erlehmann Jordach i think a good web example is the or