Z-Fighting

Поделиться
HTML-код
  • Опубликовано: 18 янв 2025

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

  • @sickleandsuckle
    @sickleandsuckle 8 лет назад +142

    This is still a frequent occurrence in games today...

    • @Bozothcow
      @Bozothcow 5 лет назад +12

      Yeah, it's actually a lot harder to mitigate then you would think. People have come up with all sorts of tricky ways to fix it but none of them are perfect.

    • @TheGreatOne93
      @TheGreatOne93 5 лет назад +11

      GTA 4 has tons of ZFighting lol especially at the airport

    • @sirrivet9557
      @sirrivet9557 4 года назад +17

      Yeah it’s probably the most common graphical glitch in games

    • @k_kubes
      @k_kubes 4 года назад

      @@sirrivet9557 this and crippling are the most common ones

    • @greenbin3028
      @greenbin3028 4 года назад

      the fix is literally just moving one texture by 1 unit

  • @maxwell6898
    @maxwell6898 6 лет назад +80

    Ive been aware of this since I was like 5, didn't know there was a name for it

    • @rixille
      @rixille 5 лет назад +4

      Same, I also have experienced seeing this in many games even when I was a kid. Fun to finally learn about it in detail.

    • @spirit8745
      @spirit8745 5 лет назад +3

      roblox lol

    • @berylharvey8395
      @berylharvey8395 3 года назад

      @@spirit8745 i hate roblox but mc also have z fighting when you mix 1 block and another with a glitch

  • @Sarmathal
    @Sarmathal 3 года назад +34

    2021 and we still have problems with z-fighting in a lot of games...

    • @K.D.Fischer_HEPHY
      @K.D.Fischer_HEPHY Год назад +3

      2023 still going strong with the z-chaos, even in modern CAD software. Dissapointing.

    • @serious643
      @serious643 Год назад +1

      nice boingo pfp

  • @NickEnchev
    @NickEnchev 4 года назад +6

    Thanks for tipping me off to how to fix this. My vulkan renderer had terrible z-fighting when decals were placed on top of larger models. This caused the decal quad to fight with the surface that it is on. I realized that my near-plane of 0.1 might be causing it. Setting it to 1.0 made all z-fighting completely go away and my rendered scene now looks sexy af. Thansk!

  • @tordeu409
    @tordeu409 8 лет назад +25

    First of all: Impressive series! It's immensely helpful, very detailed and easy to watch.
    Please allow me a little remark, though (Which is probably of more interest to other viewers):
    @ 9:15 you demonstrate that the back of the cube gets depth buffer values of about 0, even though the back is relatively close to the near plane.
    @ 10:30 you start to explain why: the objects closer to the camera get a "finer resolution" in the depth-buffer. But then you paint the "0" close to the far plane and that is actually reversed.
    If the "0" was close to the far plane, then all the values between the camera and "0" would be compressed into depth buffer values between -1 and 0. Whereas the relatively small distance between "0" and the far plane be turned into depth buffer values between 0 and +1. But this would mean that the values close to the camera are compressed more, and not less. Instead, the "0" is close to the near plane, so that the relatively short distance between the near plane and "0" get's 50% of the range of the depth buffer values.
    Your demonstration with the box (@ 9:15) even shows that the "0" is near the back of the cube; and thus relatively close to the near plane.

    • @JamieKingCS
      @JamieKingCS  5 лет назад +2

      I think I'm following you here. I believe in later videos I actually uncover a slight lie I told in this video showing the cube turns inside out like a top-hat.

  • @erikeggenbakstad
    @erikeggenbakstad 4 года назад +10

    Still valid!
    I am learning Unity for a hobby and this was mentioned, so thank you Jamie from 2013 ;P

  • @suntoritime
    @suntoritime 11 лет назад +21

    Wow, this is really great. Thanks so much for sharing your knowledge!

  • @Leafsw0rd
    @Leafsw0rd 4 года назад +1

    That's a really cool name for a very mundane problem.

  • @maskednil
    @maskednil 4 года назад +1

    So it has a name! I've always known it since the PS1 but never thought it was phenomenon that would be named.

  • @yordangrigorov6399
    @yordangrigorov6399 11 месяцев назад

    Thank you, Jamie for the great explanation! I wonder why we need to smash things between -1 and 1 though...

  • @Korsfare
    @Korsfare 5 лет назад +4

    already knew it, seen it many times, but epic video to link to friends that does not know what Z-Fighting is

  • @Kyle-qn9ci
    @Kyle-qn9ci 2 года назад

    Really great explanation, thank you

  • @vityazsix
    @vityazsix Год назад

    Does this mean we live in a simulation?

  • @swaggerdagger8976
    @swaggerdagger8976 3 года назад +1

    ZED FIGHT ! ZED FIGHT ! ZED FIGHT !
    WOO !

  • @RetroPlus
    @RetroPlus 3 года назад

    The bane of my existence

  • @user-lp3in2zc3d
    @user-lp3in2zc3d 6 лет назад +19

    GTA SA IS KING IN Z-FIGHTING

  • @thesral96
    @thesral96 8 лет назад +3

    I know what Z-Fighting is, and i kinda understood why the Z-Fighting showed up again as you moved the camera further out even tough the plane didn't touch the cube, but i've no idea what you mean with anything else.

    • @MostafaZeinali
      @MostafaZeinali 8 лет назад +2

      I think the near to far distance is mapped to the -1 to +1 distance with a logarithmic mapping and not a linear one. That's what the end part was all about

    • @MrReaperofDead
      @MrReaperofDead 7 лет назад

      what is this *nerd* in the video going on about???! 😬
      i came here for *porn* 😋

  • @nicosnico69
    @nicosnico69 3 года назад +1

    What is that software called?

    • @zdspider6778
      @zdspider6778 2 года назад

      Look like a homebrewed toy renderer meant to display how things look like when you tweak some of the values, meant for learning purposes, not for the general public.

  • @randomrick
    @randomrick 8 лет назад +5

    i don't know why i watched this, but it was kinda interesting :D i know z-fighting very well from early 3d games.

  • @madProgenitorDeity
    @madProgenitorDeity Месяц назад

    Not the Z-fighters I had in mind

  • @wood1188
    @wood1188 4 года назад +3

    Roblox is a perfect example

  • @therealvbw
    @therealvbw 4 года назад +1

    This still happens on other axes though right?

    • @zdspider6778
      @zdspider6778 2 года назад

      No. NDC is fixed in this regard.
      X and Y is vertical and horizontal.
      -Z is forward.

  • @swoorupjoshi8354
    @swoorupjoshi8354 7 лет назад +2

    Use double instead of floats. Profit?

    • @JamieKingCS
      @JamieKingCS  5 лет назад +2

      One would think that would remedy it, but it does not. When you try to represent an infinite range on a floating point scale, the floating point types become more super crude integers instead. Even if I had a billion-bit floating point type...compared to an infinite range...there's just no way to cover it all.

    • @TheGreatOne93
      @TheGreatOne93 5 лет назад +1

      @@JamieKingCS What about BigDecimal?

    • @linkenparis9562
      @linkenparis9562 2 года назад

      @@JamieKingCS so does it still help ?

    • @zdspider6778
      @zdspider6778 2 года назад +1

      @@linkenparis9562 It only delays it. It will still occur but from slightly further distances.
      It may seem like a quick and easy fix until you realize that floats have a performance benefit since they take up half the space of doubles. Flood the GPU cache with doubles and the performance takes a nosedive.

  • @chocolaterabbit7923
    @chocolaterabbit7923 4 года назад +4

    some people called it "seizure things" lol

  • @cutiebunnyamber3447
    @cutiebunnyamber3447 4 года назад

    h
    yt pls recommend this to peopless :((

  • @orocimarosay1447
    @orocimarosay1447 6 лет назад

    nice

  • @IceGuy369
    @IceGuy369 3 года назад +2

    How to piss off jtoh players

  • @canoflame6127
    @canoflame6127 3 года назад

    Sounds like john roblox

  • @poliplayzrobloxiancity176
    @poliplayzrobloxiancity176 4 года назад

    and in roblox too!

  • @freindlessversion2.021
    @freindlessversion2.021 7 лет назад +1

    Thought it was called zed fighting

    • @JamieKingCS
      @JamieKingCS  7 лет назад +4

      In England, yes.

    • @ryan2009cov
      @ryan2009cov 5 лет назад +2

      @@JamieKingCS Don't you mean the UK! & the rest of the English speaking world bar the US ;).

    • @JamieKingCS
      @JamieKingCS  5 лет назад

      Well I had an English lady chew me out once for calling her British. She was adamant about a difference, but alas...

    • @ryan2009cov
      @ryan2009cov 5 лет назад +1

      ​@@JamieKingCS Really? There obviously is a difference but that's kind of like you being offended by me calling you an American rather than a Utahn! Americans often conflate England and the whole UK, it is one of my biggest pet peeves! Thank you for this playlist!

    • @JamieKingCS
      @JamieKingCS  5 лет назад +1

      Glad it’s helping you out. :) and you can call me either

  • @MrReaperofDead
    @MrReaperofDead 7 лет назад +3

    *(Dragonball)* z-fighting 😀
    that's the cool kind of z-fighting. 😆

  • @ultramastercz
    @ultramastercz Год назад

    prvni

  • @soyfemboy
    @soyfemboy 3 года назад

    Lol, Grand Theft Auto 4 pc port

  • @Bloxxers_rclNotAClanner
    @Bloxxers_rclNotAClanner 3 года назад

    Lol
    Funny seizure block

  • @AmazingChineseLabSuperMeat8720
    @AmazingChineseLabSuperMeat8720 4 года назад

    Hbox lied

  • @vva3987
    @vva3987 5 лет назад

    h

  • @iceshadowluffy3630
    @iceshadowluffy3630 8 лет назад

    ?

  • @y2kona
    @y2kona 3 года назад

    2b2t

    • @y2kona
      @y2kona 3 года назад

      @Mati.falcon ik but i came here from a 2b2t video lol

  • @ДанилДубинин-д1п
    @ДанилДубинин-д1п 9 месяцев назад

    Z-Fighting + V-Fighting = Special Military Operation