What is Mode 7? Let's code it!

  Рет қаралды 38,703

Coder Space

Coder Space

Жыл бұрын

Creating a pseudo 3D effect using Mode 7 in Python and Pygame
Github:
github.com/StanislavPetrovV/M...
#coderspace #mode7 #pygame #python

Пікірлер: 69
@VanillaMidgetSSBM
@VanillaMidgetSSBM 11 ай бұрын
Something I want to point out - This is **not** Mode 7, this is simply a perspective projection (which, while was possible using Mode 7, was not the only purpose) Mode 7 on the Super Nintendo was a Hardware Acceleration feature that allowed a background layer to be adjusted using an Affine Transformation.
@AkaiKnight
@AkaiKnight 2 ай бұрын
*adjusts glasses* "well, acktually..."
@zerobyte802
@zerobyte802 28 күн бұрын
Retro Game Mechanics Explained covers this topic in his SNES series. The familiar “mode 7” perspective also depends on HDMA varying the scale factor over time as the screen is drawn.
@eddievhfan1984
@eddievhfan1984 Жыл бұрын
It's worth noting that in the IRL Super NES/Super Famicom, that Mode 7 was natively only capable of doing linear matrix transformations (translate, rotate, scale, skew). In order to get these 3D perspectives, the console could run small graphics attribute updates at the end of every video scanline (H-DMA, horizontal blanking Direct Memory Access), changing the Mode 7 transformation matrix on each line to simulate a non-linear transform. This is also used to get different "sky" and "floor" patterns, as Mode 7 supported only one background layer; you'd draw the sky, then rapidly mirror the floor graphics into the graphics memory.
@ivanmironov599
@ivanmironov599 Жыл бұрын
For those who might follow along with this tutorial and write the code as it goes, note that you will not be able to get a display window to pop up (seen at 2:40 and 3:30) if you have created only a mode7 and settings file. The reason it works for them (and wasn't explained from the beginning) is because they're using PyCharm and, when they run the code in the mode7 file, their configuration is set to work off of the main file they already have coded out. Note: As of this writing, Numba is only compatible with Python 3.7-3.10, and NumPy versions 1.18-1.23. They are currently working on updating it to work with Python 3.11.
@girlsdrinkfeck
@girlsdrinkfeck 8 ай бұрын
their ? i only hear a single dude talk
@stevenray8737
@stevenray8737 Жыл бұрын
Magnificent tutorial. Brings back memories of writing a ray-caster demo many years ago.
@sulrich70
@sulrich70 Жыл бұрын
Incredible. Thank you. It’s simple the way you do this, but it’s also hard!
@gawd0r
@gawd0r Жыл бұрын
Amazing video, so beautiful to see stuff that I used to implement in days in assembly, being done in a few python lines. Excellent tutorial!
@giovannipython
@giovannipython Жыл бұрын
Yours are the state of the art of tutorials and their topics are so interesting. Your subscribers will increase soon.
@xLoxLoLex
@xLoxLoLex Жыл бұрын
I always enjoy your content so much!
@rockaripoffj
@rockaripoffj 3 ай бұрын
was looking for a tutorial like this, amazing
@cheezeebutter452
@cheezeebutter452 3 ай бұрын
I hate this recent "trend" of using ai voices in videos. Please let us hear your voice, it is not a bad one I am sure, it can't be worse than the emotionless ai voices.
@K5RTO
@K5RTO Жыл бұрын
Nice! I am really enjoying your channel. Keep up the good work.
@user-pu4eg5oq4h
@user-pu4eg5oq4h 7 ай бұрын
とても参考になる興味深い解説です! 細部まで理解して、自分でも実装してみます
@HandlebarOrionX
@HandlebarOrionX 7 ай бұрын
Such a brilliant looking effect
@randy7894
@randy7894 7 ай бұрын
Just what I needed! Ty
@omarsilva924
@omarsilva924 5 ай бұрын
Well done! Impressive channel. Love how much more you get out of pygame. I’d love if you make a video about driving game from the driver perspective
@user-dc9zo7ek5j
@user-dc9zo7ek5j Жыл бұрын
Amazing work, I remember I played a game with similar effect 15 years ago, I think it was final fantasy but I might be mistaken.
@VeraVoxel
@VeraVoxel 11 ай бұрын
you know they could easily sell a gimped piece of doom by just adding a second background, but scaled from the top instead to seem like a ceiling. And then the walls could be moving sprites. And the floor of course is the normal mode 7 layer.
@thelucin
@thelucin Жыл бұрын
wow, thanks for the new video!
@gianlucagiuman6132
@gianlucagiuman6132 Жыл бұрын
Super !! High level teacher updated on latest news for library !! i remeber the old demo on amiga....
@johneygd
@johneygd 6 ай бұрын
For two decades i always tout that mode7 could move a background in 3D space including 3D rotation in all directions,BUT as it turns out,a background doesn’t move in 3D space,instead a background is scewed,stretched,shrinked in whether form to fake 3D movement of it but in reality it just uses perspective correction to give the elussion of a background moving in 3D, Pretty clever, Same thing with sprite scaling trough software, Now even if a background and a sprite could,ve move in 3D space,i still would,ve considered that as fake 3D as well since everything would,ve be still flat anyway,except that it would,ve look smoother.
@SkyFly19853
@SkyFly19853 Жыл бұрын
I love retro style...
@dietrichdietrich7763
@dietrichdietrich7763 7 ай бұрын
wow this is very interesting. I love 3D effects.
@_ironrose
@_ironrose Жыл бұрын
great video! please continue creating tuts about interesting topics like this
@ASTERisk44946
@ASTERisk44946 Жыл бұрын
I love this I'm gonna try to make a flying game via mode 7
@costelinha1867
@costelinha1867 Жыл бұрын
People: Pygame isn't exactly suited for 3d game develpment. Coder Space: Make a shit ton of videos on how to do 3d/pseudo 3d game development in Pygame.
@zhabiboss
@zhabiboss Жыл бұрын
You should make a series with nostalgic games
@ThankYouESM
@ThankYouESM Жыл бұрын
Liked and already sub'd! I wish there was a way to also create HTML5 games at least from our Python scripts, especially because I have far more time to play smartphone games as opposed to PC games.
@user-lo2qv8wz8f
@user-lo2qv8wz8f Жыл бұрын
so nice^^
@blurayys
@blurayys Жыл бұрын
Love this! Do you think you could make a tutorial on 2.5d, where you are a 2d character in a 3d environment? (Like Pokemon Diamond and Pearl)
@CoderSpaceChannel
@CoderSpaceChannel Жыл бұрын
I'll think about it
@dekerus3
@dekerus3 Жыл бұрын
​@@CoderSpaceChannel lolz!
@spikkit
@spikkit Жыл бұрын
I was able to implement this into your previous DOOM-like tutorial, but it looks super janky. Like, it displays the floor and ceiling properly, and I have it use the players position and angle to move it around which also works, but it looks like its all detached from the walls. Any suggestions on how this could be fixed?
@spikkit
@spikkit Жыл бұрын
I think i has to do with the FOV not matching between the wall projection and the floor/ceiling projection, but I'm not sure how to remedy this.
@CoderSpaceChannel
@CoderSpaceChannel Жыл бұрын
seems to be the answer here: gamedev.stackexchange.com/questions/176347/raycasting-with-mode7
@1980y
@1980y Жыл бұрын
чувак, ты просто клевый!!очень светлый и здравый ум! спасибо за твои труды! я тобой восхищаюсь! ps да я русский...
@elModo7
@elModo7 5 ай бұрын
*Nostalgic Mode7 Fans*
@tails_the_god
@tails_the_god 11 күн бұрын
Hmmm how can i bend the plane to make it like a sonic 3 special stage style?
@phillippi2
@phillippi2 6 ай бұрын
I wonder; is it possible to use this with a Wolfenstein 3d style ray cast for drawing walls?
@djaccount5458
@djaccount5458 11 ай бұрын
Hello, how put object on projected plane, i have no idea!!!
@HrvRockstar12
@HrvRockstar12 Жыл бұрын
lol I don't even know how to get to the first menu that he got. How do you get GMS2 to recognize these files? Also - will this overwrite how Game Maker Studio 2 will run? I have other levels that do not use this.
@IdkFlyCasual
@IdkFlyCasual 7 ай бұрын
i feel as if this should be easy to add to your wolfenstein game. any tips?
@lanchanoinguyen2914
@lanchanoinguyen2914 Жыл бұрын
Which api you use?
@cookiepolice2086
@cookiepolice2086 Жыл бұрын
What does dx, dy and focal length mean? And thx.
@CoderSpaceChannel
@CoderSpaceChannel Жыл бұрын
dx, dy - increments, one step on a 2d plane, along the x and y axes fol_len - distance from the camera to our screen
@mtalhakhalid1679
@mtalhakhalid1679 Жыл бұрын
Infinite room looon like gzdoom one hahahaha
@why_i_game
@why_i_game Жыл бұрын
You have a typo in your description, "Paygame" should be "Pygame".
@CoderSpaceChannel
@CoderSpaceChannel Жыл бұрын
thanks, fixed
@why_i_game
@why_i_game Жыл бұрын
@@CoderSpaceChannel Great videos, by the way. Almost makes me want to get into coding in Python!
@liorxd2557
@liorxd2557 Жыл бұрын
you are genius :0
@tcgvsocg1458
@tcgvsocg1458 Жыл бұрын
pleae can you do the first level of game like "street of rage" but in python from very begginig to end ?
@enzetael
@enzetael Жыл бұрын
0:40 what's the name of this game?
@CoderSpaceChannel
@CoderSpaceChannel Жыл бұрын
Final Fantasy III
@enzetael
@enzetael Жыл бұрын
@@CoderSpaceChannel thanks
@MrEnergy921
@MrEnergy921 Жыл бұрын
You are the python god! :D
@ChristianGeske-yn3mr
@ChristianGeske-yn3mr Жыл бұрын
Just in time compilation in Python you just blew my mind lmao.
@MURBULBEK
@MURBULBEK Жыл бұрын
Backrooms??????
@Alpaca_4
@Alpaca_4 Жыл бұрын
Yes☠️☠️☠️☠️
@karaliseklers2531
@karaliseklers2531 Жыл бұрын
wow so many clickbait youtubers out their but u hold it down
@augustingavrilovici8951
@augustingavrilovici8951 2 ай бұрын
4:01 I tried the command and it doesn't work! Son of a program!
@xaosit8974
@xaosit8974 Жыл бұрын
я то думал, где ты пропадал, а ты вот где шляешься)
@miriamalmeida6687
@miriamalmeida6687 6 ай бұрын
Snes the best console
@backer01
@backer01 Жыл бұрын
А почему ты забросил старый канал?
@Logicatube
@Logicatube Жыл бұрын
Почему ты перешел на англоязычный ютуб?
@MrRastler
@MrRastler Жыл бұрын
Потому что, там есть монетизация :)
@doka-sp
@doka-sp 4 ай бұрын
ew, AI generated
@mark-tin
@mark-tin Жыл бұрын
Жаль что ру видео больше нет
The Beauty of Prime Numbers
10:54
Coder Space
Рет қаралды 35 М.
I made Mario Kart for the NES!!!
7:47
TeddyRoseKidd
Рет қаралды 242 М.
How many pencils can hold me up?
00:40
A4
Рет қаралды 19 МЛН
Creating a Voxel Engine (like Minecraft) from Scratch in Python
1:06:39
Giving Personality to Procedural Animations using Math
15:30
t3ssel8r
Рет қаралды 2,4 МЛН
Pseudo 3D Road #7 - sprite road-side objects
4:04
Jason Doucette
Рет қаралды 3,7 М.
I Made the Same Game in 8 Engines
12:34
Emeral
Рет қаралды 3,8 МЛН
Dear Game Developers, Stop Messing This Up!
22:19
Jonas Tyroller
Рет қаралды 677 М.
It Takes Two, lava lamps, Raymarching in Godot 4.1.
12:42
Martin Donald
Рет қаралды 50 М.
Procedural 3D Engine. Ray Marching OpenGL Tutorial
15:31
Coder Space
Рет қаралды 32 М.
I tried coding my own graphics engine
4:23
Garbaj
Рет қаралды 184 М.
How Graphics worked on the Super NES | MVG
12:19
Modern Vintage Gamer
Рет қаралды 492 М.
Make Your Own DOOM. Building and Traversing a BSP Tree
13:54
Coder Space
Рет қаралды 8 М.