2022 - Non-Euclidean Doom: what happens to a game when pi is not 3.14159…

Поделиться
HTML-код
  • Опубликовано: 23 июл 2022
  • media.ccc.de/v/mch2022-236-no...
    We all know that the value of pi is a constant with a particular immutable value. Anyone who has done any graphical programming also knows that visual rendering relies not just on pi but trigonometry more broadly as well as other mathematical techniques. If we look into the source code of the first person shooter Doom we find that the value of pi used in the game is wrong. In this talk I will explore what happens when we subtly and not so subtly break math in the source.
    Doom is a well known classic first person shooter game with source code released under the GPL in 1999. In this talk I will begin by exploring what happens to the game when we make the value of pi even more wrong. What about when we change other trigonometric functions and constants to incorrect values? How will our familiar understanding and ability to traverse this virtual world change when we do this. Are there any interesting gaming possibilities with non-Euclidean geometries? A brief segway will cover some optimization tricks made to enable the game to run well on hardware available at the time. At the end I will provide a link to other games and public source code repositories that also use an incorrect value of pi. Pointers will also be provided to allow the audience to compile their own incorrect math version of the game.
    Luke Gotszling
    program.mch2022.org/mch2022/t...
    #mch2022 #MCH2022Curatedcontent

Комментарии • 662

  • @BigFreakingCacodemon
    @BigFreakingCacodemon 12 дней назад +1984

    Pi = (Health + 1) / 201 * 3.1415...
    The world becomes more and more unhinged as you loose health. You MUST find health bonuses, soul spheres, and mega spheres in order to have a normal experience. +1 so that PI is never 0.

    • @Spikehead777
      @Spikehead777 12 дней назад +365

      I would've left out the +1 though
      You die, the game dies as well 🤣

    • @markbloom7434
      @markbloom7434 12 дней назад +174

      Sadly, PI is a const and cannot be changed during runtime.
      But yeah, that would be hilarious.

    • @yusuf_kizilkaya
      @yusuf_kizilkaya 12 дней назад +346

      ​@@markbloom7434 nothing stops you from defining PI as a variable

    • @4P5MC
      @4P5MC 12 дней назад

      ​@@yusuf_kizilkaya The lookup tables do. Granted, it's simple enough to precompute them for all health values.

    • @kirillbrest1239
      @kirillbrest1239 12 дней назад

      ​@@yusuf_kizilkayayou'd have to constantly recalculate lookup tables tho

  • @dannadx3840
    @dannadx3840 12 дней назад +1866

    Most important conclusion:
    Rounding down pi to 3 is an acceptable practice in game development

    • @AnnieC.1993
      @AnnieC.1993 11 дней назад +230

      More acceptable than whatever the fuck EA is doing

    • @SmallSpoonBrigade
      @SmallSpoonBrigade 10 дней назад +38

      In general, it depends what level of accuracy and precision you need. The smaller the circle, the larger the difference.

    • @ForgottenMyth
      @ForgottenMyth 10 дней назад +14

      @@AnnieC.1993 A dumpster fire is more acceptable

    • @soupcangaming662
      @soupcangaming662 10 дней назад +8

      @@AnnieC.1993 "pi = 3 polygons"

    • @no_name4796
      @no_name4796 9 дней назад +4

      Or just use lots of triangles instead.
      Honestly i can't really think for what you would need pi, other then round objects.
      Is there some magic optimization somewhere needing PI?

  • @memes_gbc674
    @memes_gbc674 13 дней назад +1605

    lets normalize a pi=e% speedrun

    • @NoahtheEpicGuy
      @NoahtheEpicGuy 12 дней назад +71

      heh normalize... you're funny.

    • @larseriksson1184
      @larseriksson1184 12 дней назад +7

      I read pi is on a spectrum

    • @bibo2445
      @bibo2445 11 дней назад +11

      @@NoahtheEpicGuy Heh heh shut up

    • @bruh.j4mes
      @bruh.j4mes 11 дней назад +24

      DOOM (Engineer Edition)

    • @Amberlynn_Reid
      @Amberlynn_Reid 11 дней назад +9

      Let's normalise being a 30 year old virgin

  • @PTFVBVB
    @PTFVBVB 14 дней назад +1664

    As an engineer, I use the identity of pi=e=√g

    • @wernerviehhauser94
      @wernerviehhauser94 13 дней назад +197

      And always get saved by sufficiently high safety factors

    • @keiyakins
      @keiyakins 13 дней назад +226

      pi ≈ 1. it has the right number of digits

    • @neohavic6012
      @neohavic6012 12 дней назад +78

      As a physicist I hate that I love this

    • @dsdy1205
      @dsdy1205 12 дней назад

      Found the astronomer ​@@keiyakins

    • @FunctionallyLiteratePerson
      @FunctionallyLiteratePerson 12 дней назад +69

      2=e=3=pi=sqrt(g)

  • @Evan64m
    @Evan64m 13 дней назад +864

    It turns into LSDoom

    • @SonOfMeme
      @SonOfMeme 11 дней назад +43

      DooMT

    • @martybyrnemusic
      @martybyrnemusic 11 дней назад +10

      @@SonOfMeme KetaDoom

    • @SonOfMeme
      @SonOfMeme 11 дней назад +18

      @@martybyrnemusic nah you ruined it

    • @FleshWizard69420
      @FleshWizard69420 10 дней назад +31

      ShrooM

    • @duffman18
      @duffman18 10 дней назад

      ​@@martybyrnemusic you don't understand how drugs work. At least, not ketamine. This is not how it feels to be in a k-hole. A K-Hole is weird, it's like you can't remember how you even got there, like that scene at the cafe in Inception where Di Caprio explains that you never remember the start of a dream, you never remember how you arrived there.
      The main thing about being in a k-hole is that everything kinda starts feeling like you're in a world of bubble wrap, or that everything in the world is pixelated. But it's less that you're seeing the world like that and more like you're _FEELING_ it. Time itself stops being one smooth movement and instead becomes very jittery and only progresses in distinct pixelated chunks like that too. It becomes next to impossible to move, because every step feels like it takes an absolutely monumental amount of time to happen, and you feel so shaky and your legs weak that you don't wanna risk moving anyway and so if you do, then it'll be on your hands and knees crawling so that you don't fall over.
      And sound becomes pixelated too, if that makes sense. It probably doesn't make sense, unless you've been in a k-hole before. You know like when you put your face up to a fan and start humming into it and it makes it sound weird? It's like that. Except you're the only person who can hear sound in that way, other people just hear you sounding normal.
      It's nothing like non-euclidean Doom.

  • @TerjeMathisen
    @TerjeMathisen 10 дней назад +129

    It was my friend John Cash who discovered that Doom ran by using global broadcast packets, he saw that when he used a LanAlyzer to capture the traffic from their regular night-time deathmatches on the corporate IPX net.
    When he told Carmack, Carmack replied by sending him the source code and told him to "fix it!" Cash did so and later joined Carmack and Abrash to make Quake...

    • @asuka_the_void_witch
      @asuka_the_void_witch 6 дней назад +1

      what

    • @TheOriginalCoda
      @TheOriginalCoda 6 дней назад +2

      @@asuka_the_void_witch What what?

    • @lordbored2706
      @lordbored2706 3 дня назад +2

      The Man in Black

    • @KeksimusMaximus
      @KeksimusMaximus День назад +3

      Very cool! But according to the Doom wiki, the guy was hired by Carmack for Quake 2. And he was the lead programmer there. And the man left id in 2000 and later worked on World of Warcraft at Blizzard. Talented guy. Worked as a software engineer and the passion for games led him to Carmack himself to get an offer to fix the bug in the code, all of which shaped his career in game development for years, lol

    • @TerjeMathisen
      @TerjeMathisen День назад +1

      @@KeksimusMaximus The starting at Quake 2 quote is definitely wrong: John started well before the original quake architecture had settled down, something which caused a lot of issues when Carmack's very frequent rewrites caused Cash's bot code to stop working.

  • @MichaelLesterClockwork
    @MichaelLesterClockwork 8 дней назад +117

    At university we scattered parts of a zip file for installing Doom across the generic logins used for night classes. A batch file would go and retrieve the parts, assemble them, and install, and delete itself after. To hide from the sysadmin...

  • @AdrianMagni
    @AdrianMagni 13 дней назад +873

    Carmack is always right, it's circles that are wrong!

    • @SuPeRNinJaRed
      @SuPeRNinJaRed 12 дней назад +44

      π = John Carmack

    • @Chad48309
      @Chad48309 12 дней назад +12

      This sounds like a line from The Simpsons

    • @NickiRusin
      @NickiRusin 12 дней назад +24

      of course the circles are wrong if they're coming up against supergenious alien in person suit John Carmack

    • @seltzer666
      @seltzer666 10 дней назад +9

      psychic supersoldier prototype and brazilian jiu jitsu practitioner john carmack?

    • @EBHsswvZUM
      @EBHsswvZUM 9 дней назад +5

      @@seltzer666 The same John Carmack who used chemlab thermite to break into his school so he could play with the school's Apple ][s.

  • @CoolAsFreya
    @CoolAsFreya 11 дней назад +184

    When he said "Pi=0 does it run?" and all the software developers in the audience confidently yell "NOOO!"

    • @M4Dbrat
      @M4Dbrat 8 дней назад +4

      The "it doesn't compile" part is interesting, because calculating the LUTs is a build step and the program that does it crashes.
      And the segfaults happen because it tries to look up a value for an angle that's not in the table, I assume

    • @Serenity_Dee
      @Serenity_Dee 7 дней назад +3

      Yeah, I figured it would throw a divide by zero error or, because of the lookup table, an indexing error.

  • @pleasantivan
    @pleasantivan 12 дней назад +994

    10:33 me trying to play doom after the lobotomy:

    • @monad_tcp
      @monad_tcp 11 дней назад

      you should have two lobotomies, not only one.

    • @xanderplayz3446
      @xanderplayz3446 11 дней назад +2

      ???

    • @Skiivin
      @Skiivin 11 дней назад +90

      @@xanderplayz3446sorry, let me explain it for you. It’s them trying to play doom after the lobotomy

    • @user-cj3pk2tm9s
      @user-cj3pk2tm9s 11 дней назад +31

      Me trying to understand words after the lobotomy

    • @dispenser6257
      @dispenser6257 11 дней назад +4

      #relatable

  • @veiledAutonym
    @veiledAutonym 14 дней назад +442

    Now I want to make the lookup tables dynamic and make damage / healing cause the tables to regenerate with a value of pi with accuracy based on remaining health

    • @thehellriddenBaron
      @thehellriddenBaron 12 дней назад +37

      Damn, that actually sounds really dope. Throw in some palette magic and maybe even texture shifting, sprite scaling or sound pitching as well while you're at it :D

    • @hornylink
      @hornylink 11 дней назад

      or use dynamic tables that changes the value of pi to something between 2.5 and 3.3 every x seconds

    • @BradenBest
      @BradenBest 10 дней назад +22

      ​@@thehellriddenBaron I saw this suggestion (linking pi to your health) in another comment and got nerd sniped by it. Long story short, I uploaded a video to my channel of me attempting to play nightmare with this change, and it's very cursed. In fact that's the title of the video. "Doom E1M1 Nightmare Difficulty but it's cursed". I also included the git diff in a gitlab snippet which is linked in the description.
      It would probably be more balanced being normalized to a range other than 1-100. Right now it's clamped to 1 so dying doesn't crash the game, but by the time you're below 50 health, you've already lost because basic navigation becomes impossible. Like, I'm in E1M2 right now and I'm stuck in the east stair wing because I can't turn around to get to the door.

    • @robin9740
      @robin9740 10 дней назад +2

      ​@@BradenBestWoooow that's awesome!

    • @bosobot
      @bosobot 10 дней назад

      @@BradenBest real one

  • @MrSkaizZ
    @MrSkaizZ 12 дней назад +479

    I love the Jpeg injection part. Now the question isn't "can it run doom ?", it is "can it run on doom ?"

    • @landspide
      @landspide 11 дней назад +45

      "can doom load run doom?"

    • @JoshWiniberg
      @JoshWiniberg 11 дней назад +47

      DoomOS

    • @thecatofnineswords
      @thecatofnineswords 10 дней назад +6

      That was indeed very cool.

    • @lilwyvern4
      @lilwyvern4 10 дней назад +12

      @@landspide I'm fairly certain I've seen that. But maybe I'm just remembering that time someone (technically) got it running in Minecraft via redstone.

    • @ryanstedman41
      @ryanstedman41 8 дней назад +3

      @@JoshWinibergnew linux distro idea. based on arch to further solidify the meme value

  • @yellowblanka6058
    @yellowblanka6058 11 дней назад +117

    The “I hope somebody got fired for that blunder” was a tongue-in-cheek Simpsons reference, lol

    • @dave7922
      @dave7922 6 дней назад +5

      “Pi is equal to exactly three!!!”

    • @zimriel
      @zimriel 17 минут назад

      @@dave7922 not in Indiana, it's legally four by state law

  • @surthing6711
    @surthing6711 12 дней назад +217

    imagine making a friend on acid play the 3π version while he thinks its just normal doom

    • @zloidooraque0
      @zloidooraque0 11 дней назад +27

      probably will look normal to him and he will doubt acid kicked in

    • @benturner6270
      @benturner6270 9 дней назад +5

      "these tabs were bunk, man. you got burned"

  • @plasma5545
    @plasma5545 13 дней назад +350

    breathes really heavily into your ear "yeah"

    • @yobson
      @yobson 13 дней назад +81

      it's yeah, pretty yeah, a little... yeah

    • @SkilledTadpole
      @SkilledTadpole 12 дней назад +47

      "so now it starts to just be yeah it's uh it's yeah um a little yeah pretty pretty hard"

    • @JuanMendoza-qd5lm
      @JuanMendoza-qd5lm 12 дней назад +15

      ​@@SkilledTadpole Boioioioioioing🍆

    • @zelda_smile
      @zelda_smile 11 дней назад +4

      "I bet he's thinking about that hottie in front of us"
      Him:

    • @KingLich451
      @KingLich451 11 дней назад +3

      ​@@zelda_smilenothing hotter than my fridge running doom

  • @Kazuo1G
    @Kazuo1G Год назад +162

    Pi over 2: You have collapsed space-time into a smaller area. XD

  • @Dayanto
    @Dayanto 12 дней назад +63

    An issue with this is that the maps are still euclidean even though the rendering is not, so you get a clash between different geometries.

    • @stefanhoffmann5281
      @stefanhoffmann5281 11 дней назад +6

      I am also sure ist Not an real non euclidea geometry. You need tensor calculations. Objects are warped and don't disappear

    • @RKroese
      @RKroese 11 дней назад +4

      ​@@stefanhoffmann5281but the objects are 2D. Either visible or non visible.

    • @stefanhoffmann5281
      @stefanhoffmann5281 11 дней назад +1

      @@RKroese nope : read Riemann

    • @XENOGOD
      @XENOGOD 9 дней назад

      @@stefanhoffmann5281 read riemann what exactly? any specific theorems/results you could point to?

    • @ellowell8160
      @ellowell8160 18 часов назад

      @@stefanhoffmann5281 If it breaks the rules of euclidean geometry, then that is not euclidean geometry. non-euclidean. it's not specifying what it is, just what it isn't.

  • @the_pieces_fit
    @the_pieces_fit 15 дней назад +137

    8:37 when the shrooms hit

    • @haydenlandry3837
      @haydenlandry3837 13 дней назад +14

      Things are a little off, the walls move in a way that you don't expect, amd things start to shift 🤣🤣🤣

    • @ChaplainDMK
      @ChaplainDMK 11 дней назад +14

      Movies trying to show how a trip looks: *pink floating elephants everywhere*
      Actually how a trip looks like: *Doom with Pi=e*

    • @FleshWizard69420
      @FleshWizard69420 10 дней назад +4

      Shrooms will eat a slice of your pi

    • @PsychonauticExplorer
      @PsychonauticExplorer 7 дней назад +4

      Shrooms hit in a nearby forrest once and I wanted to walk home as the mosquitos bugged me... normally a 15 min walk now felt like walking around in a maze. Everything further away than the tips of my shoes didn't make sense anymore... everything I focused on in front of me became an individual and isolated piece/snapshot of reality suspended in a void as if my brain lost the ability to "glue" the pieces together and turn everything in a coherent reality, which made navigating very challenging. A weak mind would've probably freaked out, I thought it was as interesting as it was annoying. The interesting part was having a direct experience on how bits and pieces of smaller realities become a coherent big reality.

    • @RaposaCadela
      @RaposaCadela 7 дней назад

      kinda accurate actually huh

  • @julianaradanas6346
    @julianaradanas6346 10 месяцев назад +113

    This is why all the cthulu mythos inhabitants go insane lol

    • @RKroese
      @RKroese 11 дней назад +2

      Omg Carmack is Cthulu

  • @paultapping9510
    @paultapping9510 12 дней назад +58

    wait. That timeline though? Doom was released in 92 but opensourced in 1997? Opensourcing a game after just 5 years of release is wild, considering modern aaa are still expecting players to purchase games made 10+ years ago for modern day, adjusted for inflation, full-price.

    • @vytah
      @vytah 12 дней назад +62

      90s were a period of rapid technological breakthroughs, a game would look completely outdated after just a few years. Quake came out in 1996, and it had a fully 3D graphics engine with free look. At that point, a game like Doom had no market value.

    • @paultapping9510
      @paultapping9510 12 дней назад +9

      @vytah indeed, indeed. It's such a trip seeing how quite much has changed in the intervening years. Such a shame we don't live in the timeline where this is still the norm (opensourcing older games, that is).

    • @atifarshad7624
      @atifarshad7624 11 дней назад +13

      1993 actually. Doom released in December 1993 and became source code was released in December 1997. So just 4 years.

    • @ThePurplePassage
      @ThePurplePassage 11 дней назад +14

      It's not the actual game (as in levels, graphics, sounds etc) that was made free, just the engine source code - unless you were going to pirate Doom then you would have been expected to pay for it

    • @psykauze
      @psykauze 9 дней назад +4

      The Doom's distribution was initially a shareware. Meaning the Game Engine was free to share and use but not the contents of the game itself (maps, graphics, sounds...).
      Elite had just released the source code of the game engine, by doing this, the game is technically playable and saleable on everything.

  • @The-Anathema
    @The-Anathema 13 дней назад +221

    The question really is, between pi and 4, where exactly does it segfault. It clearly doesn't like pi=4 but likes pi=3.141952654 so where is the cutoff? Is 3.5 fine? 3.75? 3.25?

    • @4rumani
      @4rumani 12 дней назад +36

      I thought about this too. Why didn't he put this in his talk??

    • @sophiacristina
      @sophiacristina 12 дней назад +24

      And why would it segfault to begin with?!

    • @mrgunn3r904
      @mrgunn3r904 12 дней назад +12

      Theres probably a bounding limit on the functions used , maybe they limited the domaine of definition to - pi to pi. And since the real pi is smaller by the the pi coded it works. Idk tho just a hypothesis

    • @The-Anathema
      @The-Anathema 12 дней назад +18

      Maybe, but then that would require the function to have the correct definition of PI as well. More probably the maths result in a runtime error (division by zero or other illegal operation) at some value greater than pi.
      It's also worth noting that carmack's wrong pi is technically larger than pi, by 0.0000000003 but still it *is* larger, so the precise cutoff would be interesting (and the effects thereof likely subtle since 4 crashes)
      Anyway, it'd be trivial enough to test this myself but I don't actually care enough to do that. I just wish it was covered in the talk is all.
      Hell, given a few minutes I could work through the code and figure out why it crashes too but again: not worth the effort.

    • @Blxz
      @Blxz 11 дней назад +19

      More interesting questions than does it play at -1000000. The talk had the bones of a good concept but not properly explored.

  • @dymaxion3988
    @dymaxion3988 9 дней назад +5

    I like how the slide spelled it “segway” instead of “segue” - the homophone-induced visual metaphor is so strong for me that they’re just the same word in my mind

  • @PlatFormerlyKno
    @PlatFormerlyKno 11 дней назад +22

    someone make me a sign that says if you are here for euclidean doom you're in the wrong room 😂

  • @bigginsmcsauce
    @bigginsmcsauce 12 дней назад +62

    pi=3 is basically Playstation 1 mode!

  • @GingkoBalboa142
    @GingkoBalboa142 4 дня назад +2

    I know nothing about programming and I do math on my fingers but I find this absolutely fascinating.

  • @knightrider585
    @knightrider585 9 дней назад +4

    I think for most of the history of trigonometry the fastest way to calculate trig functions was using pre-computed tables.

  • @helium73
    @helium73 14 дней назад +103

    I wonder if you could use this for VR games. That way you can walk for miles without leaving your room. You'd probably get dizzy because you'd have to end up walking in cricles. However what if for every pi you used 2*pi that way you are trying to go left in the game but you actually walk in a circle. In order to walk slightly right you walk in a circle. Or maybe a straight line in the game requires you to walk in a circle. Maybe you could do it outside you walk in a large circle to go in a straight line. Turning left requires more turning than turning right. And going in a straight line requires turning.

    • @saschabaer3327
      @saschabaer3327 14 дней назад +64

      This sounds like motion sickness: the game

    • @bb010g
      @bb010g 14 дней назад

      Check out Hyperbolica.

    • @Neubulae
      @Neubulae 13 дней назад +8

      It's been around for a while and wobbling your head changes direction. Motion Sickness: The Game it is!

    • @breathlessblizzard
      @breathlessblizzard 13 дней назад +30

      This exists! It is called "Redirected Walking" in research papers, see Nilsson et al, IEEE 2015

    • @enoua5222
      @enoua5222 13 дней назад

      Check out Hyperbolica! It's a VR game with noneuclidean spaces -- the main hub area has 5 squares to a corner so it has more space per space

  • @SuPeRNinJaRed
    @SuPeRNinJaRed 12 дней назад +49

    I’d say “π = e” is the sweet spot 9:33 (aka DrunkDOOM) but ShroomDoom at 10:20 might be a little too high...

  • @SeveralGhost
    @SeveralGhost 8 дней назад +10

    The next frontier isnt what can we run doom on, its what we can run in doom. Asteroids is just the first step.

  • @forbiddenera
    @forbiddenera 13 дней назад +95

    9:20 but what aboit non-hitscan weapons? Those might be fkd

    • @ph0end
      @ph0end 12 дней назад +21

      yeah I really wanted to see a rocket

    • @makipri
      @makipri 5 дней назад +1

      BFG-9000!

    • @ph0end
      @ph0end 4 дня назад +1

      @@makipri
      I could be wrong but given that the only examples shown on his slides of the Doom splash-screen are those from the shareware doom1.wad, I think that's what he was using in this demonstration. If so, Plasma Rifle and BFG are unavailable even with cheats; the only non-hitscan weapon he could have shown was the Rocket Launcher.

    • @megan00b8
      @megan00b8 3 дня назад +1

      ​@@ph0endTechnically enemies like imps fire non hitscan projectiles.

  • @kargaroc386
    @kargaroc386 11 дней назад +70

    Speedrunners: "What's code injection? I've never heard about that before and don't know what you can do with it."
    (and then they get told)
    "Oh its arbitrary code execution? cool"

  • @draco18s
    @draco18s 9 дней назад +7

    I just submitted a bug report to a Google project and a Starlink project that had this wrong value of pi present.
    It makes me giggle like a little girl to know that even such large companies have replicated this discrepancy.

    • @CellGames2006
      @CellGames2006 6 дней назад

      Heheh, imagine non-Euclidean geometry causing Musk's spaceships to explode...

  • @ObscuraDeCapra
    @ObscuraDeCapra 9 дней назад +5

    Having spent way too much time in E1M1 in my life... this makes my skin absolutely crawl in a way I can't adequately explain.

  • @Oli1974
    @Oli1974 9 дней назад +3

    Lovecraft would have loved that. He anticipated that in his famous story "The Call of Ctulhu": "... and twisted menace and suspense lurked leeringly in those crazily elusive angles of carven rock where a second glance shewed concavity after the first shewed convexity."

  • @vapourmile
    @vapourmile 11 дней назад +63

    I think programmers should stop abusing the term "non-Euclidian". If you screw with the variables (or constants) in a program so it doesn't work properly anymore that isn't non-Euclidian it's just intentionally introducing bugs into a program which still uses Euclidian geometry only it doesn't produce the calculations you expect.

    • @nowonmetube
      @nowonmetube 8 дней назад +8

      Yesn't

    • @troyjohnson2137
      @troyjohnson2137 8 дней назад +6

      so you're telling me that making a euclidian world work in a way that breaks the euclidian part of it doesn't make it non-euclidian?

    • @vapourmile
      @vapourmile 8 дней назад +5

      @@troyjohnson2137
      It isn't breaking anything. It's just changing the formula.
      If you swap 2 + 3 = 5 for 2.1 + 3 = 5.1 you haven't broken anything.

    • @SebastianGrantElKiva
      @SebastianGrantElKiva 7 дней назад

      @@nowonmetube😂

    • @bramvanduijn8086
      @bramvanduijn8086 7 дней назад +2

      Doesn't the change to pi make movement of the character non-euclidian? Well technically, the character doesn't move, the world moves around the character, but it does so relative to the player, so it is in essence a circle around the character. So by changing the value of pi, that circle now has a curvature stronger or weaker than it should have. Which makes it non-euclidian, yes?

  • @selfworm
    @selfworm 5 дней назад +3

    Reminds me of MIT's "A Slower Speed of Light" for some reason

  • @antonc81
    @antonc81 11 дней назад +16

    Let’s take it into the imaginary realm:
    Pi = i

  • @facundosoler2200
    @facundosoler2200 5 дней назад +1

    That was a very fun talk given that code is involved ! Its amazing to see that after 30 years since launched this game is still disscused and studied. What a technical breakthrough Doom was ! ❤🎉

  • @RoamingAdhocrat
    @RoamingAdhocrat 12 дней назад +35

    not sure I've ever been nauseated by a tech talk before

  • @champagnesupernova1839
    @champagnesupernova1839 12 дней назад +32

    code injection via jpg? so you could port pico-8 stuff to run on doom?

    • @abcpea
      @abcpea 12 дней назад +11

      but will it run Doom?

    • @xs246
      @xs246 12 дней назад +9

      to run Doom on Doom

    • @champagnesupernova1839
      @champagnesupernova1839 12 дней назад +9

      @@abcpea someone did port doom to the pico-8, so it might be possible :3

    • @dawid035
      @dawid035 9 дней назад +1

      ​@@champagnesupernova1839It could be, which makes it even more interesting

  • @unic0de-yvr
    @unic0de-yvr 11 дней назад +18

    "...and smokes of assorted types." Nice, very subtle.

  • @scmstr
    @scmstr 13 дней назад +23

    I wonder if you could find the limits, figure out a way for the values and tables to be recalculated every tick, and then modulate the base value of pi with a (limited) feedback loop of something else, like the player's health or the look vert angle or some combination of who-knows-what-else.

    • @philipegoulet448
      @philipegoulet448 13 дней назад +1

      That would be so sick!

    • @scmstr
      @scmstr 12 дней назад +3

      @@philipegoulet448 you could even make it so it wouldn't update if you didn't move location, so that you had a *chance* at gaining a bearing.

  • @MinhTran-freespirit
    @MinhTran-freespirit 12 дней назад +31

    "I bet he's thinking about that hottie in front of us"
    Him:

  • @tylerduncan5908
    @tylerduncan5908 10 дней назад +4

    The largest value of pi I would assume is whatever value that the lookup table will no longer be able to compute.

  • @drd2093
    @drd2093 11 дней назад +4

    “Hyperbolica” on Oculus Quest deserves special mention. Non-Euclidean vr is fun

  • @Spax_
    @Spax_ 13 дней назад +21

    well now I'm really curious what the highest value pi can be while keeping the game playable

    • @yixing09
      @yixing09 10 дней назад +3

      same here. he had a whole gradient over numbers lower than pi, and none noticeably greater than pi

    • @seriouscat2231
      @seriouscat2231 9 дней назад +5

      If the lookup table for tangents had 4096 slots, then it's probably π + (π / 4096) or something like that, which causes an additional value in the table to become infinity or switch sign.

  • @timburlingame5893
    @timburlingame5893 7 дней назад +2

    *sporadic half-hearted clapping*
    "Thank you for the warm welcome."

  • @pastorpresent4940
    @pastorpresent4940 19 дней назад +10

    I used to play this a lot as a kid; it was fun but also a frightening experience

  • @JetJockey87
    @JetJockey87 7 дней назад +1

    Software Engineer - Data Platforms here. Precomputing via LUTs is such a great strat. I use it all the time, especially when you don't need reactive concurrency for data retrieval.
    Say you've got a PowerBI model (ugh IKR), selecting from data on that model takes compute, DAX on the query takes compute... Say, why don't we use a CTE to precompute the results for the semantic model? Then we can just create a holding table and truncate it and insert from the view every time we want to run this report.
    Well that just removed a lot of compute time for end users!
    And since we're inserting a whole dataset, we can then alias that against anything else we might want precomputed... How about a date slicer with historical values grouped by date? Dynamic, complex, historical queries. In PowerBI. Resolved to the end user in 0.001s
    Powerful stuff LUTs.
    Oh they also make LODs a lot easier in Game Design. Dame with lighting and reflection probes too actually.

  • @ObiwanNekody
    @ObiwanNekody 8 дней назад +4

    You didn't try the Indiana Legal pi of 3.2 😢

  • @ObviousSchism
    @ObviousSchism 12 дней назад +2

    Such an enjoyable presentation. Thanks for this!

    • @cichlisuite2
      @cichlisuite2 9 дней назад

      I wish I could understand why anyone would think this. I'm trying to put myself in the shoes of a software engineer and still can't see how I would find this entertaining or even mildly interesting? If you can explain it, I'm curious?

    • @nickkohlmann
      @nickkohlmann 9 дней назад +1

      ​@cichlisuite2 I randomly came across this. I have no idea about code or developing, neither am I good at maths. I clicked it out of pure curiosity expecting the game to look trippy with changed pi values, and it did. That was neat :) Hence me liking this.

    • @cichlisuite2
      @cichlisuite2 9 дней назад

      @@nickkohlmann Thanks for the explanation. I also randomly came across it and watched hoping it might show something interesting. It wasn't that trippy to my eyes and the presentation style was about as drab as it could be. But good to know that for some the visuals alone were enough to generate enjoyment. I thought maybe you might have to understand coding or game mechanics.

    • @bramvanduijn8086
      @bramvanduijn8086 7 дней назад

      @@cichlisuite2 You never think "what would the universe look lik e if the constants are different?" or "what would it be like to live in a two dimensional world?" If you would like to explore the second question, go read the book Flatland by A. Square.

  • @keithincomics6102
    @keithincomics6102 11 дней назад +10

    Stuff like this makes math look cool. If I had lessons in high school that allowed me to slice open Doom and play around then maybe I wouldn't have had to take Algebra II three fucking times.

  • @marcocorrieri3681
    @marcocorrieri3681 8 дней назад

    Guys... I really love you so much... thanks a lot! I was searching for an inspiration for describing not euclidean spaces in a Call of Cthulhu adventure. Now i have it

  • @kjeldgaard0
    @kjeldgaard0 9 дней назад +1

    If you compute the circumference of Earth using the incorrect value, the result is 4 cm larger than using the correct value, so errors are negligible. However, it would be interesting to use the value 3.2 for pi in this simulation, since this was the value proposed in the Indiana pi bill of 1897, that sought to fix the value of pi once and for all. Using the Indiana value for pi, the calculation of Earth's circumference would be 742.6 km too large.

  • @blusterhash
    @blusterhash 12 дней назад +1

    Lol, that was my idea for day of PI 14 of March, glad that somebody made this already and i don't have to recompile any doom port for that :)

  • @henriquereisjr6771
    @henriquereisjr6771 10 дней назад +2

    This is what Lovecraft was talking about.

  • @MrJC1
    @MrJC1 9 дней назад +1

    holy moly... PI being 3 is trippy as ballz man.

  • @jimmy_jamesjams_a_lot4171
    @jimmy_jamesjams_a_lot4171 2 дня назад

    SO MANY firsts to my disbelief. I mean, this is a first person shooting game, and doesn’t even employ DirectX because it’s from a time before DirectX - probably 10 years before or more. I can recall a few of my very first encounters with l desktop computers where x86 machines required the user to type a few DOS commands to actually start up Doom. Reminds me of Sierra games. The guys who created Doom though - must be some awesome people - for giving Doom the open source licensing at a time when Napster would be the big media buzz for a couple years at least… what great and special times these software engineers helped bring to us!

  • @shotasdg3679
    @shotasdg3679 12 дней назад +1

    I love those kind of talk

  • @BinExis
    @BinExis День назад

    As one professor said "pi is close to 5, which is close to 2pi, so you can just use 10".

  • @idogaming3532
    @idogaming3532 10 дней назад +1

    What would make this really weird is if the object hitboxes and the map were actually moving. I don't think they are, since they are determined by the map developer, without need for pi (they are simple co-ords)

  • @MexieMex
    @MexieMex День назад

    Great talk

  • @oz9884
    @oz9884 5 дней назад +1

    I think 3.5 would have been an interesting one to try, between pi and 4

  • @Oli1974
    @Oli1974 9 дней назад +1

    I was missing pi=3.15 or something like that. Would have been interesting for what values of fake_pi > pi it still would have been playable.

  • @jazzad
    @jazzad 22 часа назад

    I find comfort in the idea that a 30 year old code is still relevant and usable today. It's a hint that coding games is slowly becoming an art of its own.

  • @markykid8760
    @markykid8760 2 дня назад +1

    “I hope someone got fired for that blunder” is a simpsons reference. They didn’t mean it I'm sure

  • @davidgarcia1163
    @davidgarcia1163 3 дня назад

    I love how with this crowd the question "Why do anything like this?" is not asked, or even considered.

  • @amigalemming
    @amigalemming День назад

    18:15 I would change the sine table to a triangle waveform, thus making the unit circle a diamond.

  • @user-yf8fe8xl8d
    @user-yf8fe8xl8d День назад

    That was magnificent.

  • @erickdredd
    @erickdredd 11 дней назад +2

    I wonder if pi=3.2 will work. If so, that needs to be released as "Indiana Doom"

  • @ZeMovinPixxle
    @ZeMovinPixxle 12 дней назад +24

    as an engineer, put a highpass filter on that audio, holy shit that rumble... why?

    • @arenomusic
      @arenomusic 12 дней назад +4

      As a mechanical engineer this really fucks with my audio engineering sensibilities, won't this in-person conference speaker think of the RUclips sound quality?!

    • @ZeMovinPixxle
      @ZeMovinPixxle 12 дней назад +9

      @@arenomusic can easily be done in post quickly before an upload. fuck, id do it for free

    • @arenomusic
      @arenomusic 12 дней назад +1

      @@ZeMovinPixxle Wasn't watching with headphones but I get what you mean 😂 It's part of the IMMERSION

    • @ZeMovinPixxle
      @ZeMovinPixxle 12 дней назад +7

      @@arenomusic i work events sometimes and we always put a highpass on every microphone.

    • @ictogon
      @ictogon 12 дней назад

      It's for artistic effect

  • @altusshow7574
    @altusshow7574 6 дней назад +1

    I like this video becasue im not knowledgeable enough to understand the JPEG injection part, but im delighted that the audeince did and it made them happy.

  • @ABCDE1120
    @ABCDE1120 День назад

    Very interesting

  • @anon_y_mousse
    @anon_y_mousse 10 дней назад +1

    It seems kind of odd, but computing trigonometric functions in hardware has gotten so fast that on modern hardware it beats table-driven functions. Partly that's an accuracy issue, but if we don't mind weird visual artifacting, then I guess it doesn't matter, and clearly there are games now that use the effect intentionally.

  • @tomdavies6443
    @tomdavies6443 9 дней назад +2

    Are there harmonic resonance points along the substituted value for pi?
    Regards from a Tom :)

  • @TheJmax04
    @TheJmax04 9 дней назад +1

    I'm not sure that this is actually non-euclidean, but I'm interested in what is actually going on under the surface here.

  • @mathgeniuszach
    @mathgeniuszach 11 дней назад +2

    since computers are powerful enough, you could have some code that periodically changes the lookup table values based on new values of pi. That would be interesting to see

    • @bramvanduijn8086
      @bramvanduijn8086 7 дней назад +1

      Or calculate them instead of looking up, if you're going to be updating the lookup tables anyway the performance boost from using lookup tables is gone.
      That way you can put powerups in the map that change all sorts of constants.

  • @KingMob4313
    @KingMob4313 12 дней назад +41

    Pi = 3 - Biblically Accurate Doom

  • @IsakGerson
    @IsakGerson День назад

    This was pretty fun and interesting for me as a total non-programmer and non-hacker (except for some high school java)

  • @TiagoTiagoT
    @TiagoTiagoT 10 дней назад

    Would be interesting to see what that actually do to the geometry of the space and how/if things change relative to player or camera movement and stuff like that.

  • @samiraperi467
    @samiraperi467 9 дней назад +1

    The reason for lookup tables wasn't that there was no 3D acceleration. The reason was that you couldn't assume there was an FPU! The first Intel x86 chip with an integrated FPU was the Pentium (originally with its FDIV bug). 386 and 486 didn't have one. That's a bit of an egregious error to make in a presentation like this.

    • @makipri
      @makipri 5 дней назад

      486 already had an integrated FPU. en.m.wikipedia.org/wiki/I486

  • @evancourtney7746
    @evancourtney7746 11 дней назад +3

    So what's the convergence function for non-euclidean Doom playability?

  • @Raven3one
    @Raven3one 11 дней назад

    That was so cool!

  • @kilianlindberg
    @kilianlindberg 7 дней назад

    8:53 I ❤ this

  • @amigalemming
    @amigalemming День назад

    It was also Quake that used the reciprocal square root hack. I think they have accepted certain inaccuracies.

  • @etaidade3983
    @etaidade3983 12 дней назад +7

    I think this is the closest I will ever get to being a 4th dimensional being

  • @heyimgoingtoplaysomegames
    @heyimgoingtoplaysomegames 3 дня назад

    This is how I perceive moving through higher dimensions with a 3D body

  • @demonicsquid7217
    @demonicsquid7217 9 дней назад +1

    22/7 is where it's at...

  • @tsvtsvtsv
    @tsvtsvtsv 8 дней назад

    this is funny. i just watched another conference which started with a discussion on pi and i think the lecturer used that same incorrect approximation as an icebreaker

  • @gregh378
    @gregh378 9 дней назад

    That was brilliant

  • @MJOLNIRMARKSIX
    @MJOLNIRMARKSIX 4 дня назад +1

    New difficulty for speed runners unlocked Pi=e enemies disappear if they turn sideways 🤣

  • @tinkeringtim7999
    @tinkeringtim7999 8 дней назад +2

    Its not really non-euclidean geometry with a fixed value of pi, its just a bug. Value of pi would vary with position/size of circle in a euclidean geometry. It can't be fixed at 3.

  • @davidinark
    @davidinark 6 месяцев назад +12

    Best TED Talk ever 😂😂

  • @user-pc5sc7zi9j
    @user-pc5sc7zi9j 9 дней назад +1

    6:00 my guess is that fetching the value from memory takes way less clockcycles than doing the math.
    Source: Slaping together a pseudo-sine signal generator from some 8-bit Amtel uC and a resistor DAC half a decade ago.

    • @qazmatron
      @qazmatron 6 дней назад +1

      Half a decade? Or 0.4875 decade?

  • @survidmt
    @survidmt 8 дней назад

    Even in these 93 terms, I may as well be a fly on the wall listening to some conversation in from some remote village in the Andes or could be an alien outpost on an unknow planet.

  • @hueyiroquois3839
    @hueyiroquois3839 9 дней назад +1

    4:20 Did he not have a pocket calculator at his disposal?

  • @void6432
    @void6432 11 дней назад +3

    The question is no longer can it play Doom, the question is weather you can.

  • @angelapianomusicstudio3816
    @angelapianomusicstudio3816 7 дней назад

    Might have to speedrun this.

  • @codahighland
    @codahighland 5 дней назад

    For the record, that's STILL the fast way to do trig functions.

  • @Tuckerslam
    @Tuckerslam 12 дней назад +8

    >guitars
    Hackers in 1993 were so much cooler.