Movatterモバイル変換


[0]ホーム

URL:


Jump to content
WikipediaThe Free Encyclopedia
Search

Doom engine

From Wikipedia, the free encyclopedia
1993 game engine
id Tech 1
Developer(s)id Software (John Carmack, John Romero, Dave Taylor)
Final release
1.9 / February 1, 1995; 30 years ago (1995-02-01)
Repositorygithub.com/id-Software/DOOM
Written inC,Assembly language
PlatformMS-DOS,PC-98,Windows,Mac,Linux,Android,Amiga,NeXTSTEP,NeXT,Jaguar,32X,PlayStation,3DO,Nintendo 64,Saturn,Game Boy Advance,Switch,BSD,Unix, others
PredecessorWolfenstein 3D engine
SuccessorQuake engine
LicenseGNU GPL-2.0-or-later[1]
3DO:MIT[2]

id Tech 1, also known as theDoom engine, is thegame engine used in theid Softwarevideo gamesDoom andDoom II: Hell on Earth. It is also used inHeretic,Hexen: Beyond Heretic,Strife: Quest for the Sigil,Hacx: Twitch 'n Kill,Freedoom, and other games produced by licensees. It was created byJohn Carmack, with auxiliary functions written byMike Abrash,John Romero,Dave Taylor, and Paul Radek. Originally developed onNeXT computers,[3] it wasported toMS-DOS and compatible operating systems forDoom's initial release and was later ported to severalgame consoles andoperating systems.

Thesource code to theLinux version ofDoom was released to the public under a license that granted rights to non-commercial use on December 23, 1997, followed by the Linux version ofDoom II about a week later on December 29, 1997.[4][5] The source code was later re-released under theGNU General Public License v2.0 or later on October 3, 1999.[6][7]The dozens of unofficialDoom source ports that have been created since then allowDoom to run on previously unsupported operating systems and sometimes radically expand the engine's functionality with new features.

Although the engine renders a 3D space, that space is projected from a two-dimensionalfloor plan. The line of sight is always parallel to the floor, walls must be perpendicular to the floors, and it is not possible to create multi-level structures or sloped areas (floors and ceilings with different angles). Despite these limitations, the engine represented a technological leap from id's previousWolfenstein 3D engine. TheDoom engine was later renamed[citation needed] to "id Tech 1" in order to categorize it in a list ofid Software's long line of game engines.[8]

Game world

[edit]

TheDoom engine separates rendering from the rest of the game. The graphics engine runs as fast as possible, but the game world runs at 35 frames per second regardless of the hardware, so multiple players can play against each other using computers of varying performance.[9]

Level structure

[edit]

A simple setup demonstrating howDoom represents levels internally

Map view in editor

Viewed from the top down, allDoom levels are actually two-dimensional, demonstrating one of the key limitations of theDoom engine:room-over-room is not possible. This limitation, however, has a silver lining: a "map mode" can be easily displayed, which represents the walls and the player's position, much like the first image to the right.

Basic objects

[edit]

The base unit is thevertex, which represents a single 2D point. Vertices (or "vertexes" as they are referred to internally) are then joined to formlines, known as "linedefs". Each linedef can have either one or two sides, which are known as "sidedefs". Sidedefs are then grouped together to formpolygons; these are called "sectors". Sectors represent particular areas of the level.

Sectors

[edit]

Each sector contains a number of properties: a floor height, ceiling height, light level, a floortexture and a ceiling texture. To have a different light level in a particular area, for example, a new sector must be created for that area with a different light level. One-sided linedefs therefore represent solid walls, while two-sided linedefs represent bridge lines between sectors.

Sidedefs

[edit]

Sidedefs are used to store walltextures; these are completely separate from the floor and ceiling textures. Each sidedef can have three textures; these are called the middle, upper and lower textures. In one-sided linedefs, only the middle texture is used for the texture on the wall. In two-sided linedefs, the situation is more complex. The lower and upper textures are used to fill the gaps where adjacent sectors have different floor and ceiling heights: lower textures are used for steps, for example. The sidedefs can have a middle texture as well, although most do not; this is used to make textures hang in mid air. For example, when a transparent bar texture is seen forming a cage, this is an example of a middle texture on a two-sided linedef.

Binary space partitioning

[edit]

Doom makes use of a system known asbinary space partitioning (BSP).[10] A tool is used to generate the BSP data for a level beforehand. This process can take quite some time for a large level. It is because of this that it is not possible to move the walls inDoom; while doors and lifts move up and down, none of them ever move sideways.

The level is divided up into abinary tree: each location in the tree is a "node" which represents a particular area of the level (with the root node representing the entire level). At each branch of the tree there is a dividing line which divides the area of the node into two subnodes. At the same time, the dividing line divides linedefs into line segments called "segs".[11]

At the leaves of the tree areconvex polygons, where further division of the level is not needed. These convex polygons are referred to as subsectors (or "SSECTORS"), and are bound to a particular sector. Each subsector has a list of segs associated with it.[10]

The BSP system sorts the subsectors into the right order for rendering. The algorithm is fairly simple:

  1. Start at the root node.
  2. Draw the child nodes of this node recursively. The child node closest to the camera is drawn first using aScanline algorithm. This can be found from looking at which side of the node's dividing line the camera is on.
  3. When a subsector is reached, draw it.[12]

The process is complete when the whole column of pixels is filled (i.e., there are no more gaps left). This ordering ensures that no time is used drawing objects that are not visible and as a result maps can become very large without any speed penalty.

Rendering

[edit]
This sectiondoes notcite anysources. Please helpimprove this section byadding citations to reliable sources. Unsourced material may be challenged andremoved.(January 2012) (Learn how and when to remove this message)
This sectionpossibly containsoriginal research. Pleaseimprove it byverifying the claims made and addinginline citations. Statements consisting only of original research should be removed.(February 2023) (Learn how and when to remove this message)

Drawing the walls

[edit]

All of the walls inDoom are drawn vertically; it is because of this that it is not possible to properly look up and down. It is possible to perform a form of look up/down via"y-shearing", and many modernDoom source ports do this, as well as later games that use the engine, such asHeretic. Essentially this works by moving the horizon line up and down within the screen, in effect providing a "window" on a taller viewable area. By moving the window up and down, it is possible to give the illusion of looking up and down. However, this will distort the view the further up and down the player looks.

TheDoom engine renders the walls as it traverses the BSP tree, drawing subsectors by order of distance from the camera so that the closest segs are drawn first. As the segs are drawn, they are stored in a linked list. This is used to clip other segs rendered later on, reducing overdraw. This is also used later to clip the edges of sprites.

Once the engine reaches a solid (1-sided) wall at a particular x coordinate, no more lines need to be drawn at that area. For clipping the engine stores a "map" of areas of the screen where solid walls have been reached. This allows far away parts of the level which are invisible to the player to be clipped completely.

TheDoom graphic format stores the wall textures assets of vertical columns; this is useful to the renderer, which essentially renders the walls by drawing many vertical columns of textures.

Floor and ceiling

[edit]

The system for drawing floors and ceilings ("flats") is less elegant[according to whom?] than that used for the walls. Flats are drawn with aflood fill-like algorithm. Because of this, if a bad BSP builder is used, it is sometimes possible to get "holes" where the floor or ceiling bleeds down to the edges of the screen, a visual error commonly referred to as a "slime trail".[13] This is also the reason why if the player travels outside of the level using thenoclip cheat the floors and ceilings will appear to stretch out from the level over the empty space.

The floor and ceiling are drawn as "visplanes". These represent horizontal runs of texture, from a floor or ceiling at a particular height, light level and texture (if two adjacent sectors have exactly the same floor, these can get merged into one visplane). Each x position in the visplane has a particular vertical line of texture which is to be drawn.

Because of this limit of drawing one vertical line at each x position, it is sometimes necessary to split visplanes into multiple visplanes. For example, consider viewing a floor with twoconcentric squares. The inner square will vertically divide the surrounding floor. In that horizontal range where the inner square is drawn, two visplanes are needed for the surrounding floor.

Doom contained a static limit on the number of visplanes; if exceeded, a "visplane overflow" would occur, causing the game to exit to DOS with one of two errors, "No more visplanes!" or "visplane overflow (128 or higher)". The easiest way to invoke the visplane limit is a large checkerboard floor pattern; this creates a large number of visplanes.

As the segs are rendered, visplanes are also added, extending from the edges of the segs towards the vertical edges of the screen. These extend until they reach existing visplanes. Because of the way this works, the system is dependent on the fact that segs are rendered in order by the overall engine; it is necessary to draw nearer visplanes first, so that they can "cut off" by others further away. If unstopped, the floor or ceiling will "bleed out" to the edges of the screen, as previously described. Eventually, the visplanes form a "map" of particular areas of the screen in which to draw particular textures.

While visplanes are constructed essentially from vertical "strips", the actual low level rendering is performed in the form of horizontal "spans" of texture. After all the visplanes have been constructed, they are converted into spans which are then rendered to the screen. This appears to be a trade off: it is easier to construct visplanes as vertical strips, but because of the nature of how the floor and ceiling textures appear it is easier to draw them as horizontal strips.

Things (sprites)

[edit]

Each sector within the level has a linked list of things stored in that sector. As each sector is drawn the sprites are placed into a list of sprites to be drawn. If not within the field of view these are ignored.

The edges of sprites are clipped by checking the list of segs previously drawn. Sprites inDoom are stored in the same column based format as the walls are, which again is useful for the renderer. The same functions which are used to draw walls are used to draw sprites as well.

While subsectors are guaranteed to be in order, the sprites within them are not.Doom stores a list of sprites to be drawn ("vissprites") and sorts the list before rendering. Far away sprites are drawn before close ones. This causes some overdraw but usually this is negligible.

There is a final issue of middle textures on 2-sided lines, used in transparent bars for example. These are mixed in and drawn with the sprites at the end of the rendering process, rather than with the other walls.

Games using theDoom engine

[edit]

TheDoom engine achieved most of its fame as a result of powering the classic first person shooterDoom, and it was used in several other games. It is usually considered that the "Big Four"Doom engine games areDoom,Heretic,Hexen: Beyond Heretic, andStrife: Quest for the Sigil.

Games built directly on theDoom engine

[edit]
YearTitleDeveloper
1993Doomid Software
1994Doom II: Hell on Earth
HereticRaven Software
1995Hexen: Beyond HereticRaven Software
1996Final DoomTeamTNT
Heretic: Shadow of the Serpent RidersRaven Software
Hexen: Deathkings of the Dark Citadel
Strife: Quest for the SigilRogue Entertainment

Games based on theDoom orDoom II code

[edit]

In the 1990s a handful of developers acquired licenses to distributetotal conversions ofDoom, and following the 1997 source code release a number of standalone titles have been produced in the engine, includingfreeware,fangames and commercial titles.[14]

YearTitleDeveloper
1996Killing Time (PC)Logicware
Chex QuestDigital Café
1997Doom 64Midway Studios San Diego
Chex Quest 2: Flemoids Take ChextropolisDigital Café
HacXBanjo Software
2000Sonic Robo Blast 2Sonic Team Junior
2003FreedoomFreedoom Team
2008Chex Quest 3Charles Jacobi
BlasphemerBlasphemer Team
Action Doom 2: Urban Brawl[15]Scuba Steve
2009Harmony[16]Thomas van der Velden
2014The Adventures of Square[17]BigBrik Games
2016Blade of Agony[18]Daniel Gimmer
2017Rise of the Wool Ball[19]MSPaintR0cks
2018REKKR[20]Mockingbird Softworks
Annie[21]SergeJkn
Ashes[22]Vostyok
Total Chaos[23]wadaholic
2019Hocus Pocus Doom[24]Ravage
Hedon[25]Zan_HedonDev
Shrine[26]Scumhead
2020Project Osiris[27]ArcturusDeluxe
2021Castlevania: Simon’s Destiny[28]batandy
Vomitoreum[29]Scumhead
2022Hands Of Necromancy[30]HON Team
Fashion Police Squad[31]Mopeful Games
CountryCide[32]TrenchWork
Project Absentia[33]Waffle Iron Studios
I Am Sakuya: Touhou FPS Game[citation needed]Sigyaad Team
2023Beyond Sunset[34]Metacorp / Vaporware
Supplice[35]Mekworx
Venturous[36]PixelFox
Apocalyptic Vibes[37]Amanito Computing
2024Hands of Necromancy 2[38]HON Team
Beyond Sunset[39]Metacorp / Vaporware
Selaco[40]Altered Orbit Studios
Borrowhelen[41]4-Cube Games

See also

[edit]

Notes

[edit]

References

[edit]
  1. ^"Doom source code, under the GNU GPL".gamers.org.Archived from the original on 31 May 2023.
  2. ^"Doom3do/LICENSE at master · Olde-Skuul/Doom3do".GitHub. 17 December 2022.Archived from the original on 19 February 2022. Retrieved14 February 2019.
  3. ^"NeXT Computers - Company - Computing History".www.computinghistory.org.uk.Archived from the original on 2022-03-29. Retrieved2022-03-29.
  4. ^Staff (December 29, 1997)."Doom II Source Available".PC Gamer US. Archived fromthe original on February 18, 1998. RetrievedNovember 20, 2019.
  5. ^https://web.archive.org/web/*/ftp://ftp.idsoftware.com/idstuff/source/*ftp://ftp.idsoftware.com/idstuff/source/[permanent dead link]
  6. ^"Doom source code, under the GNU GPL - Doomworld /idgames database frontend".Archived from the original on 2021-03-28. Retrieved2021-03-28.
  7. ^TheDoom source code from 3ddownloads.comArchived February 24, 2004, at theWayback Machine - released in 1997, now under theGNU GPL v2-or-later
  8. ^"id Tech 1 (Concept)".Giant Bomb.Archived from the original on 2019-02-15. Retrieved2019-02-14.
  9. ^Schuytema, Paul C. (August 1994)."The Lighter Side Of Doom".Computer Gaming World. pp. 140, 142.Archived from the original on 2018-01-02. Retrieved2019-02-14.
  10. ^abAbrash, Michael."Quake's 3-D Engine: The Big Picture". Retrieved22 August 2012.
  11. ^Apted, Andrew."SPECIFICATION for GL-Nodes".Archived from the original on 2 September 2012. Retrieved22 August 2012.
  12. ^Sanglard, Fabien."Doom engine code review".Archived from the original on 3 September 2012. Retrieved23 August 2012.
  13. ^Slime trail - The Doom Wiki
  14. ^Tarason, Dominic (2019-04-01)."Modder Superior: The many free descendants of Doom".Rock Paper Shotgun.Archived from the original on 2023-08-06. Retrieved2024-07-14.
  15. ^Yu, Derek (2008-01-09)."Action Doom 2: Urban Brawl".tigsource. Retrieved2008-01-09.
  16. ^Gillen, Kieron (2009-11-18)."Harmony in My Head: Harmony".Rock Paper Shotgun.Archived from the original on 2023-02-23. Retrieved2023-02-22.
  17. ^Dawe, Liam (2018-04-19)."The Adventures of Square is mildly amusing retro FPS that's free with a second episode out now".GamingOnLinux. Retrieved2023-02-19.
  18. ^Smith, Adam (2016-08-03)."Blade Of Agony Is An Incredible 'WolfenDoom' Mod".rockpapershotgun. Retrieved2016-08-03.
  19. ^Tarason, Dominic (2018-01-07)."Shadow & Rise Of The Wool Ball turn Wolfenstein cute".Rock Paper Shotgun.Archived from the original on 2024-07-15. Retrieved2024-07-14.
  20. ^Tsiro, Rania (2018-07-12)."Doomguy Is Now Some Kind Of Viking In The Rekkr Game".VGR.Archived from the original on 2024-07-15. Retrieved2024-07-14.
  21. ^Glagowski, Peter (2018-08-17)."Doom 2 mod Annie rises after 12 year development period".destructoid. Retrieved2018-08-17.
  22. ^Tarason, Dominic (2018-09-24)."Brave a very 80s apocalyptic wasteland in Doom conversion Ashes 2063".rockpapershotgun.Archived from the original on 2021-06-17. Retrieved2018-09-24.
  23. ^Dawe, Liam (2018-11-05)."Total Chaos is an impressive and scary total conversion for Doom 2 making it a survival horror experience".gamingonlinux. Retrieved2018-11-05.
  24. ^Tarason, Dominic (2019-01-14)."Hocus Pocus Doom drags Apogee's DOS platformer into the third dimension".rockpapershotgun. Retrieved2019-01-14.
  25. ^Digre, Alyxx (2019-05-16)."Hedon – PC Game Review".VGR.Archived from the original on 2024-07-15. Retrieved2024-07-14.
  26. ^Bolding, Jonathan (2019-12-27)."Butcher some cosmic horrors in Doom 2 mod Shrine".pcgamesn. Retrieved2019-12-27.
  27. ^Papadopoulos, John (2020-03-16)."Someone has created an Alien Breed 3D Remake in GZDoom, and you can download it right now".DSOGaming. Retrieved2024-06-22.
  28. ^Tarason, Dominic (2021-06-27)."Castlevania: Simon's Destiny is a treat of a Doom mod".rockpapershotgun. Retrieved2021-06-27.
  29. ^Glagowski, Peter (2021-08-11)."Vomitoreum Review".Tech Raptor.Archived from the original on 2024-07-15. Retrieved2024-07-14.
  30. ^Dawe, Liam (2022-05-22)."GZDoom powered dark-fantasy FPS 'Hands of Necromancy' is out now".GamingOnLinux. Retrieved2024-07-15.
  31. ^Lane, Rick (2022-08-15)."'Fashion Police Squad' review: groom eternal".nme. Retrieved2022-08-15.
  32. ^Werner, Adrian (2022-04-22)."CountryCide - New Version of Stunning Dark Mod for Doom 2".gamepressure. Retrieved2022-04-22.
  33. ^"Project Absentia". 30 October 2022.
  34. ^Handley, Zoey (2023-10-08)."GZDoom FPS Beyond Sunset begins its Early Access stint today".destructoid. Retrieved2023-10-08.
  35. ^Chalk, Andy (2023-08-05)."Supplice is a new retro-FPS made by Doom modders, and it really feels like old-school Doom".PCGamer. Retrieved2023-06-05.
  36. ^Zwiezen, Zack (2023-09-29)."New Doom Mod Is Basically A Badass Indiana Jones Game".kotaku. Retrieved2023-09-29.
  37. ^Tamaster, Tamaster (2023-03-21)."Apocalyptic Vibes – An Immersive Journey Through a Faded-out, Post-Nuclear Earth!".indie-hive. Retrieved2023-03-21.
  38. ^McHugh, Alex (2024-09-17)."New retro FPS Hands of Necromancy 2 looks to Heretic for inspiration".pcgamesn. Retrieved2024-09-17.
  39. ^Smith, Mova (2023-12-14)."Retro FPS Beyond Sunset is a precision-crafted cyberpunk potpourri of all the great megawads that came before it".pcgamer. Retrieved2023-12-14.
  40. ^Zwiezen, Zack (2024-05-31)."New FPS Built Using Doom Tech Is Better Than Most AAA Shooters".Kotaku.Archived from the original on 2024-07-15. Retrieved2024-07-14.
  41. ^Kotaky, Kotaku (2024-11-25)."Borrowhelen Screenshots and Videos - Kotaku".Kotaku. Retrieved2024-11-25.

External links

[edit]
Main franchises
Other games
Games published
People
Current
Former
Publishers
Technology
Related
Main series
Spin-offs
Other media
Novels
Films
Other
Universe
Technology
Mods
Doom &
Doom II
Doom 3
Companies
Related
Proprietary
1980s
1990s
2000s
2010s
2020s
Free and
open-source
1970s
1990s
2000s
2010s
2020s
Retrieved from "https://en.wikipedia.org/w/index.php?title=Doom_engine&oldid=1282469596"
Categories:
Hidden categories:

[8]ページ先頭

©2009-2025 Movatter.jp