Frame rate sync. How to enable or disable vertical sync in games

In almost all modern games in the graphics settings, you can see the "vertical sync" column. And more and more players have questions Is this synchronization useful?, its impact and why it exists at all, how to use it on various platforms. Let's find out in this article.

About vertical sync

Before proceeding directly to an explanation of the nature of vertical synchronization, it is necessary to delve a little into the history of the formation of vertical synchronization. I'll try to be as clear as possible. The first computer monitors were a fixed image served by a single frame scan signal.

By the time a new generation of displays appeared, the question of changing the resolution sharply arose, which required several modes of operation, those displays presented a picture using the polarity of the signals synchronously to the vertical.

The VGA resolution required more fine tuning sweep and was given two signals horizontally and vertically. In today's displays, the built-in controller is responsible for setting the scan.

But if the controller, according to the driver, sets the required number of frames, why do you need vertical synchronization for the set resolution? It is not that simple. Quite often there are situations when the frame rate of generating a video card is very high, but monitors, due to their technical limitations, unable to display this number of frames correctly when the monitor's refresh rate is significantly lower than the graphics card's refresh rate. This leads to sharp image movements, artifacts and stripes.

Not having time to show frames from the memory file with "triple buffering" enabled, they quickly replace themselves, superimposing the next frames. And here the technology of triple buffering is almost ineffective.

The vertical sync technology designed to remedy these shortcomings..

She accesses the monitor with a poll for the standard refresh rate and frame rate, not allowing frames from the secondary memory to go to the primary, exactly until the moment the image is updated.

Connecting the vertical sync

The vast majority of games have this function in their graphics settings directly. But it happens when there is no such column, or certain defects are observed when working with the graphics of applications that do not include settings for such parameters.

In the settings of each video card, you can enable vertical sync technology for all applications or selectively.

How to enable for NVidia?

Like most manipulations with NVidia cards, it is done through the NVidia management console. There, in the 3D parameter control graph, there will be a sync pulse parameter.

It should be moved to the on position. But depending on the video card, the order will be different.

So in older video cards, the vertical sync parameter is in the chapter global options in the same 3D settings control box.

Video cards from ATI

To configure, use the control center for your graphics card. Namely, the Catalyst Control Center is running the .NET Framework 1.1. If you do not have it, then the control center will not start. But don't worry. In such cases, there is an alternative to the center, just working with the classic control panel.

To access the settings, go to the 3D item located in the menu on the left. There will be a Wait for Vertical Refresh section. Initially, the default vertical sync technology is used within the application.

Moving the button to the left will completely disable this feature, and moving it to the right will force it on. The default option is here the most reasonable, as it makes it possible to configure synchronization directly through the game settings.

Summing up

Vertical synchronization is a function that helps to get rid of sharp movements in the picture, in some cases it allows you to get rid of artifacts and stripes in the image. And this is achieved by double buffering the received frame rate when the frame rate of the monitor and video card do not match.

Today, v-sync is in most games. It works in much the same way as triple buffering, but costs much fewer resources, which is why triple buffering in game settings can be seen less often.

By choosing to enable or disable vertical sync, the user makes a choice between quality and performance. By turning it on, it gets a smoother picture, but fewer frames per second.

Disabling the same, he gets more frames, but is not immune from the sharpness and slovenliness of the picture. In particular this applies intense and resource-intensive scenes, where the lack of vertical sync or triple buffering is particularly noticeable.

This mysterious graph in the parameters of many games was not as simple as it seemed. And now the choice to use it or not, remains only with you and your goals in the games.

What is vertical sync in games? This function is responsible for the correct display of games on standard LCD monitors with a frequency of 60 Hz. When enabled, the frame rate is limited to 60Hz and no interruptions are displayed on the screen. Disabling it will increase the frame rate, but at the same time, there will be a screen tearing effect.

V-sync is a rather controversial topic in games. On the one hand, for a visually comfortable gaming experience, it seems to be very necessary, provided that you have a standard LCD monitor.

Thanks to it, no errors appear on the screen during the game, the picture is stable and has no gaps. The downside is that the frame rate is capped at 60Hz, so more demanding players may experience what is called input lag, that is, a slight delay when moving in the game with the mouse (can be equated with artificially smoothed mouse movement).

Disabling vertical sync also has its pros and cons. First of all, an unlimited FPS frame rate is provided and thereby completely removes the mentioned input lag. This is useful in games like Counter-Strike, where reaction and accuracy are important. Movement and aiming is very clear, dynamic, every movement of the mouse occurs with high precision. In some cases, we can get a higher FPS rate, since V-Sync, depending on the video card, can slightly reduce hardware performance (the difference is about 3-5 FPS). Unfortunately, the disadvantage is that without vertical sync, we get a screen tearing effect. When turning or changing movement in the game, we notice that the image is torn into two or three horizontal parts.

Enable or disable V-Sync?

Is vertical sync necessary? It all depends on our individual preferences and what we want to get. In multiplayer FPS games, it is recommended to turn off vertical sync to improve aim accuracy. The screen tearing effect, as a rule, is not so noticeable, and when we get used to it, we will not even notice it.

In turn, in story games, you can safely turn on V-Sync. Here, high accuracy is not so important, the first violin is played by the environment, visual comfort, so you should bet on good quality.

Vertical sync can usually be turned on or off in the game's graphics settings. But if we don’t find such a function there, then you can manually turn it off manually in the video card settings - both for everyone, and only for selected applications.

Vertical sync on NVIDIA graphics cards

On GeForce graphics cards, the feature is located in the Nvidia Control Panel. Right-click on the Windows 10 desktop and then select Nvidia Control Panel.

In the sidebar, select the 3D Settings Controls tab under 3D Settings. The available settings will be displayed on the right.

Settings are divided into two tabs - global and program. On the first tab, you can set options for all games and, for example, whether to enable or disable vertical sync in each. Whereas on the second tab you can set the same parameters, but individually for each game separately.

Select the global or program tab, and then look for the "Vertical Sync" option in the list. There is a drop-down field next to it - we choose to force turn off or turn on vertical synchronization.

V-Sync on AMD graphics

In the case of AMD graphics cards, it looks exactly the same as in Nvidia. Right click on the desktop and then go to the Panel Catalyst Control Center.

Then open the "Games" tab on the left and select "Settings for 3D applications". On the right, a list of available options will be displayed that can be forced to be enabled from the position of the AMD Radeon graphics settings. When we are on the "System Settings" tab, we select for everyone.

If you need to set the parameters individually for each game separately, then you should click on the "Add" button and specify the EXE file. It will be added to the list as a new bookmark, and when you switch to it, you can set parameters only for this game.

When you have selected the tab with the added application or system parameters (general), then find the option "Wait for vertical update" in the list. A selection box will appear where we can forcibly enable or disable this option.

V-Sync on integrated Intel HD Graphics

If using an integrated Intel HD Graphics chip, a control panel is also available. It should be available by right-clicking on the desktop or via the Ctrl+Alt+F12 key combination.

On the Intel panel, go to the Settings Mode tab - Control Panel - 3D Graphics, and then to the user settings.

Here we find a field with vertical synchronization Vertical Sync. You can enable it forcibly by setting the value to "Enabled" or set it to "Application Settings". Unfortunately, there is no force disable feature in the Intel HD card options - you can only enable V-Sync. Since it is not possible to disable vertical synchronization in the video card, this can only be done in the settings of the game itself.

Translating... Translate Chinese (Simplified) Chinese (Traditional) English French German Italian Portuguese Russian Spanish Turkish

Unfortunately, we are unable to translate this information right now - please try again later.

Learn how to use a simple algorithm to synchronize the image with the display refresh rate and improve the quality of video playback.

Introduction

Our vision of a “digital home” is gradually becoming a reality. In recent years, more and more devices for the "digital home" have been commercially available. The range of electronics offered is very large - from multimedia set-top boxes that support music and video broadcasting to full-scale entertainment systems in a conventional PC case.

Home media centers are becoming a standard item on computer store price lists, allowing you to watch and record TV shows, save and play digital photos and music, and so on. In addition, some vendors offer special kits with which the user can turn his PC into a home media center.

Unfortunately, such media centers do not always support high quality video playback. Insufficient video quality is usually caused by factors such as incorrect buffering and rendering of streaming content, lack of deinterlacing algorithms when processing interlaced video, and incorrect synchronization of video-audio streams. Most of these problems are well studied and have solutions, which are sufficiently taken into account by manufacturers. However, there is another, less well-known and less obvious problem that can lead to minor, but still noticeable distortion when watching videos. Our article provides a detailed description of this problem and considers one of the ways to solve it.

With the growing sales of home media centers, more and more consumers are watching TV on PCs. As this segment, which is currently in demand by amateur enthusiasts, expands, the demand for high-quality video will also increase.

There are a number of methods to improve the quality of video playback on a computer, and many video software manufacturers have successfully used them. At the same time, sometimes the fact that video playback software must take into account and ensure that the video is synchronized with the refresh rate of the display. The fact is that TVs are initially provided for synchronization with the video signal coming from the broadcasting studio. Unlike TVs, computer monitors refresh the screen at a fixed rate, which is set by the graphics adapter and has nothing to do with the video signal. This significant difference can cause a lot of problems if you want to ensure that the video is correctly synchronized with the computer display. Below we will try to give a detailed description of this problem and offer a solution. However, before that, we would like to introduce the reader to some basic concepts that will be discussed in the article.

Display refresh cycle

The refresh rate of the PC screen (screen refresh rate) is synchronized with the frequency of the graphics adapter (video card). Consider the most common example - when the video card and monitor support a frequency of 60Hz. This combination is possible due to the fact that the monitor is synchronized with the 60Hz signal coming from the video card. In fact, the monitor maintains synchronization even in cases of slight deviation in the output frequency of the graphics adapter (for example, 60.06 Hz instead of the standard 60 Hz).

During the refresh cycle, the screen image is redrawn from the display buffer (graphics adapter addressable memory). Each horizontal line on the display is sequentially updated in accordance with the new data contained in the video memory buffer. The row currently being updated is called the scan row. In the case of a 60 Hz graphics adapter, the screen refresh process occurs 60 times per second, so the image on the PC monitor is also updated 60 times per second.

Figure 1 - Display update

Image tearing artifacts

Be aware of the potential issue of non-uniform graphics buffer refresh. If the contents of the video memory buffer have changed at a time when the image on the monitor has not yet been completely drawn (the refresh cycle has not completed), then only the part of the new image following the scan line will be shown on the screen (see Fig. Rice. 2). This image artifact, which shows the old image at the top of the screen and the new image at the bottom, is called tearing. In fact, this term is very descriptive, since the resulting image looks like it is “torn” in half.

Figure 2 - Artifacts of the "gap" of the image

Team Flip

One way to prevent "tears" is to make sure that updating the contents of the video memory occurs after that how the display refresh cycle is completed and before that when the next cycle starts. In other words, the update must occur during the reverse sweep. However, this method requires corresponding changes in the software, which must calculate the order of image change with sufficient accuracy.

For this reason, a buffer switching synchronization algorithm (Flip) has been proposed. The Flip command is very simple in nature - it allows the program to update the image at any time during the screen refresh cycle, but its result is not actually transferred to video memory until the current cycle is completed. Thus, the update of the image on the monitor occurs at the interval following the execution of the Flip command. With the buffer synchronization method, "tearing" of the image is eliminated because the Flip command ensures that a complete new image is ready for each refresh cycle (see below). Rice. 3). However, in the next section, we will demonstrate that using the Flip command alone does not guarantee that all problems will be solved.

Figure 3 - Flip Command Sequence

Potential Issues

Using a synchronization algorithm has great benefits and helps eliminate tearing artifacts, but one significant problem remains.

When using the Flip command, the software rendering conditions for the video are changed. To execute Flip, the software has to adjust the frame buffer update interval (frame rate) according to a certain frame rate. The only clock rate at which frames can be synchronized is the display refresh rate (or multiple). In other words, a new frame can only be displayed at the beginning of the refresh cycle - in fact, the frame intervals are tied to the refresh rate of the display.

Figure 4 - Frame rate and display frequency mismatch

This fact implies that if the refresh rate of the display is not the same as the frame rate of the content being played, or is not a multiple of it, the content on the display cannot be fully reproduced. On the Rice. 4 a special case of this problem is shown. In this scenario, the content frame rate is slower than the display refresh rate. Due to the phase shift between these two frequencies, the Flip command intervals for two frames will eventually stretch out over a full refresh cycle (note the timing of frames 3 and 4). As a result, frame 3 will be displayed almost twice as long as required. Thus, you should strive to match the frame rate and refresh rate of the display, although this is not always possible.

The situation under consideration is only exacerbated if the difference between the frame rate and the refresh rate of the display is small. When frame times are close to update cycle intervals, even small inaccuracies in software timer calculations can cause several successive Flip commands to stumble relative to the start of the update. This means that some Flip commands will run too early and some too late, resulting in "duplicate" and "dropped" frames. This case is illustrated in Rice. 5– the timer does not work correctly (at irregular intervals), as a result, frames 2 and 4 are not shown, and frames 3 and 5 are shown twice.

Figure 5 - The result of using Flip on timer failures

This phenomenon may occur even when the frame rate of the content and the refresh rate of the display are the same. Obviously, using only a timer and the Flip command is not enough to ensure high-quality video playback. As explained in the next section, in order for the Flip commands to execute correctly, the software must maintain smart synchronization with display refresh cycles.

Timing Flip Commands

As mentioned above, the use of the Flip command allows you to take into account screen refresh cycles when rendering video frames. Each newly transmitted frame is displayed for only one complete display refresh cycle. Thus, when using the Flip command, the software must accurately calculate not only when each frame should be displayed, but also determine the specific refresh cycle in order to optimally synchronize the output of frames.

It is best to call the Flip command at the very beginning of the refresh cycle, just before the start of the corresponding frame refresh interval (see example on Rice. 3). This gives the highest probability of actually executing the command before the start of the corresponding update cycle and ensures that the frame is output at the right time. Note that in cases where the video frame rate and display refresh rate do not match, Flip's frame refresh cycle optimization is not sufficient to provide acceptable video quality. There are some ways to frame or modify content frames that resolve these issues, but they are outside the scope of this publication.

Some operating systems provide programming interfaces through which applications can keep in sync with the display's refresh cycle. In particular, the Microsoft DirectX 9.0 environment includes several procedures that can be very useful in our case. Next, we'll look at the DirectX standard procedures as exemplary methods for solving the problem under investigation. Readers can use these examples to explore the proposed methods and find similar solutions on other operating systems.

WaitForVerticalBlank() is a standard procedure in the DirectDraw library (within the IDirectDraw interface) that blocks the thread accessing the interface until the next update cycle begins. This procedure can be used for synchronization, but it should be done once or at a significant interval because it is time consuming to access. However, this procedure is useful when performing the initial synchronization with an update cycle.

GetScanLine() is a standard procedure that can be used to obtain information about which scanline is currently being updated on the display. If the total number of lines and the current scan line are known, it is not difficult to determine the state of the display refresh cycle. For example, if the total number of display lines is 1024 and the procedure GetScanLine() returns 100, the current refresh cycle is currently 100 to 1024, which is about 10 percent complete. Application GetScanLine() allows the application to monitor the state of the update loop and, based on it, determine which cycle to bind the next rendered frame to, and set a timer for the desired buffer switching time. The following is an example algorithm:

Figure 6

The frame change time is selected not only based on the calculation of new image frames, but also taking into account the screen refresh rate. Since frames are only displayed on the screen when the display is refreshed, it is necessary to make sure that each frame "hit" the correct refresh cycle. Thus, ideally, image framing should exactly match the refresh rate of the screen. In this case, each frame will be drawn on the display at the right time.

Alternative solution for recorded content

The issues we address apply to all video playback scenarios, both in the case of live broadcasts and when playing back recorded video. However, in the latter case, you can resort to an alternative solution. If the difference between the frame rate of the content and the refresh rate of the display is small, you can adjust the frame rate of the video (and adjust the audio stream in the same way) to match the screen refresh rate without compromising the quality of the content. As an example, let's take a 59.94 frames per second (Bob deinterlaced) standard definition TV signal on a monitor at 60 Hz. By accelerating video and audio playback up to 60 frames per second, you can ensure that the frame rate matches the refresh intervals of the screen and does not cause image artifacts.

Summary

This publication is devoted to image synchronization methods, in particular, the prevention of image tearing artifacts using the Flip command. The article also addresses cases where the Flip command causes problems caused by tight synchronization with display refresh cycles. Proper frame timing and the use of Flip commands can cause frame times and intervals to differ from what the software application expects. The paper concludes that the correct way to use the Flip commands is to combine Flip synchronization with the screen refresh rate and optimize the image calculation cycle in view of its subsequent output. Thus, Flip intervals can be adjusted in software. The best video quality is achieved when the frame rate of the content matches the refresh rate of the display. However, in practice this is not always achievable. The algorithms described in this article will help reduce image artifacts to a minimum.

Surely, many computer gamers have come across a recommendation to disable the so-called "vertical synchronization" or VSync in the video card settings in games.

In many graphics controller performance tests, it is emphasized that the testing was carried out with VSync disabled.
What is it, and why is it needed, if many "advanced experts" advise disabling this feature?
To understand the meaning of vertical sync, you need to make a short digression into history.

The first computer monitors ran at fixed resolutions and fixed refresh rates.
With the advent of EGA monitors, it became necessary to select different resolutions, which was provided by two modes of operation, which were set by the polarity of the image synchronization signals along the vertical.

Monitors that support VGA resolution and higher require fine-tuning of the sweep frequencies.
For this, two signals were already used, which are responsible for synchronizing the image both horizontally and vertically.
In modern monitors, a special controller chip is responsible for adjusting the scan in accordance with the set resolution.

Why is the “vertical sync” item saved in the video card settings if the monitor is able to automatically adjust in accordance with the mode set in the driver?
The fact is that, despite the fact that video cards are capable of generating a very large number of frames per second, monitors cannot display it with high quality, as a result of which various artifacts appear: banding and a “torn” image.

To avoid this, video cards provide for a mode of preliminary interrogation of the monitor about its vertical scan, with which the number of frames per second is synchronized - the familiar fps.
In other words, with a vertical frequency of 85 Hz, the number of frames per second in any game will not exceed eighty-five.

The vertical refresh rate of a monitor refers to the number of times a screen with an image is refreshed per second.
In the case of a cathode ray tube display, no matter how many frames per second the graphics accelerator allows to “squeeze” out of the game, the refresh rate cannot physically be higher than the set one.

In LCD monitors, there is no physical refresh of the entire screen: here, individual pixels may or may not glow.
However, the very technology of data transmission through the video interface provides that frames are transmitted to the monitor from the video card at a certain speed.
Therefore, with a certain degree of convention, the concept of "sweep" is applicable to the LCD display.

Where do image artifacts come from?
In any game, the number of generated frames per second is constantly changing, depending on the complexity of the picture.
Since the monitor's refresh rate is constant, the desynchronization between the fps transmitted by the video card and the monitor's refresh rate leads to image distortion, which seems to be divided into several arbitrary bands: one part of them has time to update, while the other does not.

For example, a monitor operates at a refresh rate of 75 Hz, and a video card in a game generates one hundred frames per second.
In other words, the graphics accelerator is about a third faster than the monitor refresh system.
During the update of one screen, the card generates 1 frame and a third of the next - as a result, two thirds of the current frame are drawn on the display, and its third is replaced by the third frame of the next one.

During the next update, the card manages to generate two-thirds of the frame and two-thirds of the next, and so on.
On the monitor, in every two out of three scan cycles, we observe a third of the image from another frame - the picture loses its smoothness and “twitches”.
This defect is especially noticeable in dynamic scenes or, for example, when your character in the game looks around.

However, it would be fundamentally wrong to assume that if the video card is forbidden to generate more than 75 frames per second, then everything would be in order with the display of the image on the display with a vertical frequency of 75 Hz.
The fact is that in the case of the usual, so-called "double buffering", the frames on the monitor come from the primary frame buffer (front buffer), and the rendering itself is carried out in the secondary buffer (back buffer).

As the secondary buffer fills up, frames enter the primary one, however, since the copy operation between buffers takes a certain time, if the monitor scan is updated at this moment, image twitching will still not be avoided.

Vertical synchronization just solves these problems: the monitor is interrogated for the refresh rate and copying frames from the secondary buffer to the primary is prohibited until the image is updated.
This technology works great when the frame rate per second exceeds the vertical frequency.
But what if the frame rate drops below the refresh rate?
For example, in some scenes, our fps drops from 100 to 50.

In this case, the following happens.
The image on the monitor is updated, the first frame is copied to the primary buffer, and two-thirds of the second is "rendered" in the secondary buffer, followed by another update of the image on the display.
At this time, the video card finishes processing the second frame, which it still cannot send to the primary buffer, and the next update of the image takes place with the same frame that is still stored in the primary buffer.

Then all this is repeated, and as a result we have a situation where the frame rate per second on the screen is two times lower than the scanning frequency and one third lower than the potential rendering speed: the video card first “does not keep up” with the monitor, and then it, on the contrary , you have to wait until the display retakes the frame stored in the primary buffer, and until there is room in the secondary buffer to calculate a new frame.

It turns out that in the case of vertical synchronization and double buffering, we can get a high-quality image only if the number of frames per second is equal to one of a discrete sequence of values ​​calculated as the ratio of the scanning frequency to some positive integer.
For example, with a refresh rate of 60 Hz, the number of frames per second should be 60 or 30 or 15 or 12 or 10, etc.

If the potential capabilities of the card allow you to generate less than 60 and more than 30 frames per second, then the actual rendering speed will drop to 30 fps.

Modern games use more and more graphic effects and technologies that improve the picture. At the same time, developers usually do not bother to explain what exactly they are doing. When not the most productive computer is available, some of the capabilities have to be sacrificed. Let's try to look at what the most common graphics options mean in order to better understand how to free up PC resources with minimal consequences for graphics.

Anisotropic filtering

When any texture is displayed on the monitor not in its original size, it is necessary to insert additional pixels into it or, conversely, remove the extra ones. This is done using a technique called filtering.

Bilinear filtering is the simplest algorithm and requires less computing power, but it also gives the worst result. Trilinear adds clarity but still generates artifacts. Anisotropic filtering is considered the most advanced method that eliminates noticeable distortions on objects that are strongly inclined relative to the camera. Unlike the two previous methods, it successfully fights the aliasing effect (when some parts of the texture are blurred more than others, and the border between them becomes clearly visible). When using bilinear or trilinear filtering, the texture becomes more and more blurred with increasing distance, while anisotropic filtering does not have this disadvantage.

Considering the amount of data being processed (and there can be many high-resolution 32-bit textures in a scene), anisotropic filtering is especially demanding on memory bandwidth. You can reduce traffic primarily due to texture compression, which is now used everywhere. Previously, when it was practiced less often, and the bandwidth of the video memory was much lower, anisotropic filtering significantly reduced the number of frames. On modern video cards, it has almost no effect on fps.

Anisotropic filtering has only one setting - filter factor (2x, 4x, 8x, 16x). The higher it is, the clearer and more natural the textures look. Typically, with a high value, small artifacts are only visible on the outermost pixels of tilted textures. Values ​​of 4x and 8x are usually enough to get rid of the lion's share of visual distortion. Interestingly, when going from 8x to 16x, the performance degradation will be quite small even in theory, since only a small number of previously unfiltered pixels will need additional processing.

Shaders

Shaders are small programs that can perform certain manipulations on a 3D scene, such as changing lighting, applying textures, adding post-processing, and other effects.

Shaders are divided into three types: vertex (Vertex Shader) operate with coordinates, geometric (Geometry Shader) can process not only individual vertices, but also entire geometric shapes, consisting of a maximum of 6 vertices, pixel (Pixel Shader) work with individual pixels and their parameters .

Shaders are mainly used to create new effects. Without them, the set of operations that developers could use in games is very limited. In other words, the addition of shaders made it possible to obtain new effects that were not included in the video card by default.

Shaders work very productively in parallel, which is why modern graphics adapters have so many stream processors, which are also called shaders. For example, in the GeForce GTX 580 there are as many as 512 of them.

Parallax mapping

Parallax mapping is a modified version of the well-known bumpmapping technique used to emboss textures. Parallax mapping does not create 3D objects in the usual sense of the word. For example, a floor or wall in a game scene will look rough while actually remaining completely flat. The relief effect here is achieved only through manipulations with textures.

The original object does not have to be flat. The method works on different game objects, but its use is desirable only in cases where the surface height changes smoothly. Sharp drops are processed incorrectly, and artifacts appear on the object.

Parallax mapping significantly saves computing resources of a computer, because when using analogue objects with such a detailed 3D structure, the performance of video adapters would not be enough to render scenes in real time.

The effect is most often applied to stone pavements, walls, bricks and tiles.

Anti-Aliasing

Prior to the advent of DirectX 8, anti-aliasing in games was done using SuperSampling Anti-Aliasing (SSAA), also known as Full-Scene Anti-Aliasing (FSAA). Its use led to a significant decrease in performance, so with the release of DX8 it was immediately abandoned and replaced with Multisample Anti-Aliasing (MSAA). Despite the fact that this method gave worse results, it was much more productive than its predecessor. Since then, more advanced algorithms have appeared, such as CSAA.

Given that over the past few years, the performance of video cards has increased markedly, both AMD and NVIDIA have returned support for SSAA technology to their accelerators. However, it will not be possible to use it even now in modern games, since the number of frames / s will be very low. SSAA will be effective only in projects of previous years, or in current ones, but with modest settings for other graphic parameters. AMD has implemented SSAA support only for DX9 games, but in NVIDIA SSAA also functions in DX10 and DX11 modes.

The principle of smoothing is very simple. Before the frame is displayed on the screen, certain information is calculated not in native resolution, but increased and a multiple of two. Then the result is reduced to the required size, and then the "ladder" along the edges of the object becomes less noticeable. The higher the original image and the smoothing factor (2x, 4x, 8x, 16x, 32x), the fewer steps will be on the models. MSAA, unlike FSAA, smoothes only the edges of objects, which significantly saves graphics card resources, but this technique can leave artifacts inside polygons.

Previously, Anti-Aliasing has always significantly reduced fps in games, but now it affects the number of frames slightly, and sometimes does not affect at all.

tessellation

Using tessellation in a computer model, the number of polygons is increased by an arbitrary number of times. To do this, each polygon is divided into several new ones, which are located approximately the same as the original surface. This method makes it easy to increase the detail of simple 3D objects. In this case, however, the load on the computer will also increase, and in some cases even small artifacts cannot be ruled out.

At first glance, tessellation can be confused with Parallax mapping. Although these are completely different effects, since tessellation actually changes the geometric shape of the object, and not just simulates relief. In addition, it can be used for almost any object, while the use of Parallax mapping is very limited.

Tessellation technology has been known in cinema since the 80s, but it has only recently become supported in games, or rather, after graphics accelerators finally reached the necessary level of performance at which it can be performed in real time.

In order for the game to use tessellation, it requires a graphics card that supports DirectX 11.

Vertical Sync

V-Sync is the synchronization of game frames with the monitor's vertical refresh rate. Its essence lies in the fact that a fully calculated game frame is displayed on the screen at the moment the picture is updated on it. It is important that the next frame (if it is already ready) will also appear no later and no earlier than the output of the previous one ends and the next one begins.

If the monitor refresh rate is 60 Hz, and the video card manages to render a 3D scene with at least the same number of frames, then each monitor refresh will display a new frame. In other words, with an interval of 16.66 ms, the user will see a complete update of the game scene on the screen.

It should be understood that when vertical sync is enabled, fps in the game cannot exceed the monitor's vertical refresh rate. If the number of frames is lower than this value (in our case, less than 60 Hz), then in order to avoid performance losses, it is necessary to activate triple buffering, in which frames are calculated in advance and stored in three separate buffers, which allows them to be sent to the screen more often.

The main task of vertical synchronization is to eliminate the effect of a shifted frame that occurs when the lower part of the display is filled with one frame, and the upper part is already filled with another, shifted relative to the previous one.

post-processing

This is the general name of all the effects that are applied to an already finished frame of a fully rendered 3D scene (in other words, to a two-dimensional image) to improve the quality of the final picture. Post-processing uses pixel shaders and is used in cases where additional effects require complete information about the entire scene. In isolation to individual 3D objects, such techniques cannot be applied without the appearance of artifacts in the frame.

High dynamic range (HDR)

An effect often used in game scenes with contrasting lighting. If one area of ​​the screen is very bright and another is very dark, a lot of the detail in each area is lost and it looks monotonous. HDR adds more gradations to the frame and allows you to detail the scene. To use it, you usually have to work with a wider range of shades than the standard 24-bit precision can provide. Pre-calculations occur in increased accuracy (64 or 96 bits), and only at the final stage the image is adjusted to 24 bits.

HDR is often used to implement the effect of adapting vision when the hero in games leaves a dark tunnel on a well-lit surface.

Bloom

Bloom is often used in conjunction with HDR, and it also has a fairly close relative - Glow, which is why these three techniques are often confused.

Bloom simulates the effect that can be seen when shooting very bright scenes with conventional cameras. In the resulting image, the intense light appears to take up more volume than it should, and "climbs" onto objects even though it is behind them. When using Bloom, additional artifacts in the form of colored lines may appear on the borders of objects.

Film Grain

Grain is an artifact that occurs in analog TV with a poor signal, on old magnetic video cassettes or photographs (in particular, digital images taken in low light). Players often turn off this effect, because it spoils the picture to a certain extent, and does not improve it. To understand this, you can run Mass Effect in each of the modes. In some horror films, such as Silent Hill, the noise on the screen, on the contrary, adds to the atmosphere.

motion blur

Motion Blur - the effect of blurring the image when moving the camera quickly. It can be successfully used when the scene needs to be given more dynamics and speed, therefore it is especially in demand in racing games. In shooters, the use of blur is not always perceived unambiguously. Proper application of Motion Blur can add cinematic quality to what is happening on the screen.

The effect will also help to mask low framerates if necessary and add smoothness to the gameplay.

SSAO

Ambient occlusion is a technique used to add photorealism to a scene by creating more believable illumination of the objects in it, which takes into account the presence of other objects nearby with their own characteristics of absorption and reflection of light.

Screen Space Ambient Occlusion is a modified version of Ambient Occlusion and also simulates indirect lighting and shading. The appearance of SSAO was due to the fact that at the current level of GPU performance, Ambient Occlusion could not be used to render scenes in real time. For increased performance in SSAO, you have to pay with lower quality, but even it is enough to improve the realism of the picture.

SSAO works according to a simplified scheme, but it has many advantages: the method does not depend on the complexity of the scene, does not use RAM, can function in dynamic scenes, does not require frame pre-processing, and loads only the graphics adapter without consuming CPU resources.

Cel shading

Games with the effect of Cel shading have been made since 2000, and first of all they appeared on consoles. On the PC, this technique became really popular only a couple of years after the release of the sensational shooter XIII. With Cel shading, each frame is almost like a hand-drawn drawing or a fragment from a children's cartoon.

Comics are created in a similar style, so the technique is often used in games related to them. Of the latest known releases, we can name the Borderlands shooter, where Cel shading is visible to the naked eye.

The features of the technology are the use of a limited set of colors, as well as the absence of smooth gradients. The name of the effect comes from the word Cel (Celluloid), that is, a transparent material (film) on which animated films are drawn.

Depth of field

Depth of field is the distance between the near and far edges of space, within which all objects will be in focus, while the rest of the scene will be blurred.

To a certain extent, depth of field can be observed simply by focusing on an object that is close in front of the eyes. Everything behind it will blur. The opposite is also true: if you focus on distant objects, then everything in front of them will turn out to be fuzzy.

You can see the effect of depth of field in a hypertrophied form in some photographs. It is this degree of blur that is often attempted to be simulated in 3D scenes.

In games using Depth of field, the gamer usually has a stronger sense of presence. For example, looking somewhere through the grass or bushes, he sees only small fragments of the scene in focus, which creates the illusion of presence.

Performance Impact

To find out how the inclusion of certain options affects performance, we used the Heaven DX11 Benchmark 2.5 gaming benchmark. All tests were carried out on an Intel Core2 Duo e6300, GeForce GTX460 system at 1280x800 pixels (except for vertical sync, where the resolution was 1680x1050).

As already mentioned, anisotropic filtering has almost no effect on the number of frames. The difference between disabled anisotropy and 16x is only 2 frames, so we recommend that you always set it to the maximum.

Anti-aliasing in Heaven Benchmark lowered fps more than we expected, especially in the hardest 8x mode. Nevertheless, since 2x is enough for a noticeable improvement in the picture, we advise you to choose this option if it is uncomfortable to play at higher ones.

Tessellation, unlike the previous parameters, can take on an arbitrary value in each individual game. In Heaven Benchmark, the picture deteriorates significantly without it, and at the maximum level, on the contrary, it becomes a little unrealistic. Therefore, intermediate values ​​should be set - moderate or normal.

A higher resolution was chosen for vertical sync so that fps is not limited by the vertical refresh rate of the screen. As expected, the number of frames throughout almost the entire test with the synchronization turned on was clearly at around 20 or 30 frames / s. This is due to the fact that they are displayed simultaneously with the screen refresh, and at a refresh rate of 60 Hz, this can be done not with every pulse, but only with every second (60/2 = 30 fps) or third (60/3 = 20 fps). frames/s). When V-Sync was disabled, the number of frames increased, but characteristic artifacts appeared on the screen. Triple buffering did not have any positive effect on the smoothness of the scene. Perhaps this is due to the fact that in the video card driver settings there is no option to force buffering off, and the normal deactivation is ignored by the benchmark, and it still uses this function.

If Heaven Benchmark were a game, then at maximum settings (1280×800; AA - 8x; AF - 16x; Tessellation Extreme) it would be uncomfortable to play it, since 24 frames is clearly not enough for this. With minimal loss of quality (1280×800; AA - 2x; AF - 16x, Tessellation Normal), a more acceptable 45 fps can be achieved.

Related publications