Wednesday, February 10, 2016

Screen-Space Shadows

Dynamic shadows is the one of the most slowest passes in any renderer. Especially when it comes to cascading shadows that cover huge visible region and even more. The problem is in the big number of draw calls and overdraw to the depth buffer, which is especially critical in the case of flora and grass in particular.
I was thinking about ways to effectively solve this problem. As the result I developed technique called Screen-space shadows, which allows us to get soft, stable and fast shadows from grass. Also Screen-space shadows could be used for building shadows from other small objects as well as from far mountains.
The technique in already has been using in one great game.

Here is short algorithm description:

Generate shadow stage
Do calculations in half size of screen.
Jitter P to E marching distance using screen-space random or random texture. 16-32 samples.
Result = 1
Foreach S in (E-P)
If ShouldReceive(P) and ShouldCast(S)
VtoS = DistanceToEye(S)
VtoT = DistanceToEye(T)
If VtoS < VtoT and Abs(VtoS - VtoT) < Tolerance(S) and not OutOfScreen(T)
Result = ShadowAttenuation(S) or zero
End If
End If
End Foreach
Tolerance: function of distance from V to S
ShadowAttenuation: function of distance from P to T

Next stages:
Temporal stabilization, which is the key of stabilization
Bilateral upscale, depends on quality settings
Directional blur, depends on quality settings

Some results
typical shadows:
 screen-space shadows:

Friday, April 16, 2010

Editor overview: SoundMix Editor

The SoundMixEditor is a visual editor for mixing sounds and effects.

+ Using Audiere.
+ Many nodes for sound tree modification.
+ Controlled nodes from script and database.
+ Supports 3D sound.
+ Many more.

Screen short:

Friday, April 9, 2010

Thursday, March 4, 2010

Editor overview: PostProcessEditor

Supports next post-effects:

+ Bloom
+ DepthOfField
+ MotionBlur
+ ColorCorrection
+ Material
+ Haze
+ And more.

Screen shots:

Wednesday, March 3, 2010

Editor overview: SkeletalMeshEditor

+ Animations.
+ Setting animation segments directly by hands.
+ Sockets with previews.
+ Feedbacks (play sound, call script function, attach mesh, attach partices system, more) on setted frame or time.
+ Lods. Change of amount of bones and triangles, animation update frequency, depending on ScreenFactor.
+ And more.

Screen shots:

Sunday, February 28, 2010

Editor overview: MaterialEditor updates

Post about MaterialEditor:

1. Built-in CurvesEditor to flexible control shader input - Float and the Float4 variables.
2. Added Diffuseness, Ambient, LightingMask material inputs.
3. Added new properties to material.
4. Original appearance is a bit changed.
5. Material expressions can change a size.
6. Added new material expressions: If, For, While, Arrays, etc.
7. Arrow heads to the connections lines.
8. New menu items.
9. Faster compilation.
10. The generated code can be viewed and extremely changes by hands.
11. And more.


Sunday, February 14, 2010

Static Lighting with GI

I'm currently working on implementing a static lighting with global illumination. Here are some results, baked high resolution shadows from multiple light sources of different types plus Radiosity Normal Mapping. GI comming soon.

Sunday, February 7, 2010

Editor overview: LensFlaresEditor

+ Any materials can be used in the one flare.
+ Flexible options that depend on flare offsets/distance (color/alpha/rotation/size/etc)
+ Not limited number of flares in one effect.
+ And more.


Tuesday, February 2, 2010

Editor overview: ParticesEditor


+ Built-in CurvesEditor allows to modify any values how you want.
+ You can create how many you want emittors with any materials and mashes.
+ Editor support PhysX fluids, and dynamic particles collision.
+ And more.


Wednesday, January 27, 2010

Editor overview: nodes-based MaterialEditor

Can be setted
+ Phong, Cook-Torrance, Anisotropic lighting models.
+ Different blending modes.
+ Back face material.
+ Motion blur amount.
+ Radiosity color.
+ and more.

Unlike ue3, it can be generates also vertex and geometry(dx10) shaders.


Tuesday, January 5, 2010

A few screenshots

Forward Shading:

Wednesday, December 23, 2009

First Demo

Reference deleted. Now I'm doing a larger-scale demo.

Sunday, December 20, 2009

Thursday, December 17, 2009

Sunday, November 22, 2009

Friday, October 23, 2009


Successfully implemented texture and mesh streaming, 
significantly reduced the cost of memory, 
the game world can now be much larger and detailed!

Friday, August 21, 2009

Screen-space global illumination

Продолжается разработка Realtime Global Illumination, вот неcколько скриншотов, некоторые идеи взяты отсюда

Tuesday, June 30, 2009

Sunday, June 28, 2009

Particle System (captured video)

I prepared a short video clip, which demonstrates some features of the particle system in my engine

Friday, April 24, 2009

RealTime Radiosity

Вчера встроил realtime radiosity в движок. Может не совсем radiosity, но все же.Для его работы не нужные какие-либо дополнительные расчеты.  Алгоритм одинаково работает как со статической так и с динамической геометрией. 

Вот первая небольшая демонстрация данного освещения в действии. 
Но это далеко не окончательный вариант.

Monday, March 2, 2009

Video: round of level

В другой раз постараюсь сделать видео с лучшим качеством :/

Monday, February 23, 2009

Monday, February 16, 2009

Три скриншота с рабочих уровней

Работа продолжается, вот несколько скриншотов. Просто показалось красиво, особенно с далека. DOF делает свое дело :)

Saturday, February 14, 2009

My Variant of Light Pre-Pass Renderer

About Light Pre-Pass Renderer you can read here:

I like this idea, but I don't like reading normalmap in depth/normal pass. 

My idea to store light directions multipled withN.L, without normalmap reading. 

Geometry pass to MRT(R16F, R8G8): 
In R16F we write linear depth: 
Out.Depth = In.PositionViewSpace.z / zFar; 
In R8G8 we write view space normal:
Out.NormalXY = 0.5 + 0.5 * mul(float3(0,0,1), TBN).xy; 

R16F we need for fast post-process effects speed. 

Then lighting pass: 
 Render light volumes to MRT (A16B16G16R16F, A8R8G8B8) 
 Read depth, normal; 
 Compute LightDir, LightAttenuation and N.L; 
 Out.Dir = LightAttenuation * LightDir * N_dot_L; 
 Out.Color = InLightColor * N_dot_L; 

Then color geometry pass to a A8R8G8B8: 
 Read LightDir, LightColor from LightDirBuffer and LightColorBuffer; 
 Compute N.LightDir, R.LightDir; 
 And final light geometry;
++ Dont need read normalmap in depth/normal pass; 
-- Problems only with specular when crossings more then 2 lights; 
Your opinions? 

Here is some results:

Sunday, February 1, 2009

Editor for animations blending

In English:

Editor for animations blending  is practically ready.

Now to mix up animations simpler simple. For one object can play
quite different animations of his different parts (or for separate bones), with different there is speed, in any combinations.
For example, a protagonist can simultaneously run, shoot, throw a grenade.
These animations are created separately from each other.

It is possible to manage all of this process from a scripting language or visual logic editor.

Need here yet morfing and IK :)

И на русском:

Практически готов редактор для блендинга анимаций.
Теперь смешивать анимации проще простого. Для одного объекта могут играть
совершенно разные анимации различных его частей (или для отдельных костей),
с разной скорость, в любых комбинациях. А еще костями можно двигать и без анимации.

Например, главный герой может одновременно бежать, стрелять, метать гранату. 
Причем эти анимации созданы отдельно друг от друга.

Всем этим процессом можно управлять из скриптового языка или ректора визуальной логики.

Как бы сюда еще морфинг добавить с IK :)

Wednesday, January 7, 2009

Subsurface scattering (SSS)

Simplest variant:
SSS = Fresnel * (LightAtt) + LightDiffuse + LightSpecular
With SSS: