Discussion on Engine Mode Based on D3D Effect.

xiaoxiao2021-03-05  25

A few days ago, I have been understanding the OGRE engine, I feel that the material script inside is very perfect, and the perfection here refers to the use of unique layers using it. So I started to check the D3D EFFECT information, I want to think of a structure of an engine mode from a society.

The current 3D game always encounters some problems, for example, some special effects have unique requirements for graphics cards, so that the picture effect and compatibility are difficult to guarantee. So just encountered this time company's urgent needs of the whole 3D engine, our group began to make a full 3D engine, so I decided to use D3D EFFECT for visual effects.

According to different picture visual effects, you can use different effect to render, and TechniQue inside Effect is divided into Fixed Pipeline to PS / VS 3.0 standard according to the minimum graphics, and divided into 4 different Techniques. For example, RealTime Shadow can be used from shadow mapping to Pixel Soft Shadow to achieve different levels of effect. The ground map can also achieve different effects from the detail texture to Normal Map, so that you can decide to use a Technique for each Effect when initialization, so for developers, Shader or Effect will not be exposed, they What you need to do is just to choose a different rendering effect. On the one hand, let the project department can concentrate on the logic of the game, no longer need to worry about the picture effect, and you can make the engine maintenance work. Let the picture effect and data management are separated.

I have been considering Shader's packaging problem. I want to think about any more perfect answer. Why should SHADER be determined by the application layer, or should be fixed by the engine. After several considerations and a large number of reading articles, I finally decided to encapsulate Shader to the engine, so that it is no longer visible to it. The advantage is that the development department no longer needs to spend a lot of time to consider a lot of achievements for different machine configurations, and the development of the engine has become increasingly related.

In fact, many technologies are very good, the key is how to apply, then once this interface does not stay, there is a lot of projects to be used, but because of its single implementation, it has to give up the user machine configuration and have to give up. But when you do engine demonstration, many times have to come up with the best results.

: P Sticked a recently realized bloom effect picture. .

转载请注明原文地址:https://www.9cbs.com/read-34891.html

New Post(0)