Jump to content

  • Log In with Google      Sign In   
  • Create Account

Medo3337

Member Since 24 Apr 2012
Offline Last Active Jul 13 2014 05:57 PM

#5160387 Most Efficient Way for Lighting in Forward Rendering

Posted by Medo3337 on 13 June 2014 - 05:49 PM

I'm currently using Forward Lighting and trying to do my best to make sure that the FPS game will always render all the lights

 

1. In Pixel Shader 2.0, I have

DirectionalLight dirLights[maxLights];
PointLight pointLights[maxLights];
SpotLight spotLights[maxLights];

What is the appropriate number for the variable maxLights?

 

2. Since Forward Lighting is limited to a certain amount of lights, I have been thinking that I could:

- Detect collision between the light and the camera bounding frustum and only render the light if the camera can see it

- Arrange the lights from closest to farthest to the camera and remove any light if it's index is over 'maxLights' variable

 

What do you think about my idea? What is the most efficient way to work with forward lighting?




#5110486 Shadows Problem

Posted by Medo3337 on 19 November 2013 - 09:43 AM

@belfegor: Since I'm bored, I wrote the code like that

 

But anyway that's not the point, the point is that shadows doesn't work correctly




#5107606 Computing view matrix to create shadow map

Posted by Medo3337 on 07 November 2013 - 12:05 AM

I'm trying to generate shadow map so I can pass it to the shader and create shadow

 

I have bunches of lights (including directional lights, point lights and spot lights)

 

How do I calculate the view matrix to create the shadow map?




#5097736 Rendering only what the camera see

Posted by Medo3337 on 29 September 2013 - 11:33 PM

For getting higher performance, is there is anyway to render ONLY what the camera see?
 
Since it's not really important to render anything that the camera can't see



#5092469 Skybox VS Skysphere

Posted by Medo3337 on 08 September 2013 - 07:22 AM

What is most used commonly in modern FPS games?

 

Can I use cube map on skysphere?

 

Some sky textures looks very good on the texture but when I try to apply it to the sky sphere it doesn't look as good as it was, that's why I'm thinking that I could use cube map.




#5092375 Skybox VS Skysphere

Posted by Medo3337 on 07 September 2013 - 07:31 PM

Hi guys,

 

What's your recommendations? Should I use sky box or sky sphere?

 

If I used sky sphere, should I apply cube texture to the sphere or just a single texture?

 

What is more commonly used especially in FPS games? Which one can produce better sky and which is easier for producing different looking skies?




#5091826 Particles Depth Problem

Posted by Medo3337 on 05 September 2013 - 11:30 AM

Thanks MJP

 

One last depth problem:

When I disable soft particles, the particles appears in front of the camera ALL THE TIME even if they are very far away and I have many buildings much closer, I can still see the particles (while I shouldn't).




#5090082 Blending Two Animations

Posted by Medo3337 on 29 August 2013 - 05:40 AM

@Tispe: Let me explain to you better:

 

Available Animation presets:

- Walk

- Run

- Reload

 

Here is example:

character->walk();
delay(5000); // Delay for 5 seconds
character->reload();

What do I expect from the above code?

The character starting walking and after 5 seconds he will reload his weapon WHILE still walking.

 

What happens instead?

The character start walking, but when he reload, the "walking" animation RESET

 

What should happen?

When the character reload his weapon, the animation transition should only affect his arms and not his legs, the walking sequence should not get affected

 

I can only resolve this problem when I don't have animation smooth transition by only changing the intended animation track while leaving the other as it is, but how do I fix it while I have smooth transition?




#5089805 Blending Two Animations

Posted by Medo3337 on 28 August 2013 - 06:49 AM

Lets say I have 4 different animation presets inside "character.x":

- Idle

- Walking

- Running

- Reloading weapon

 

I can play any of them, switch between idle to walking smoothly, but

 

How do I play both animations "running and reloading weapon" at the same time?

 

I have been looking for any code sample to accomplish that using D3D9 but I didn't find any.

 

I'm using D3D9 Animation Controller ID3DXAnimationController.




#5087368 Collision between particles (Planes) and Box

Posted by Medo3337 on 19 August 2013 - 01:14 PM

blink.png

 

I have been trying to do it myself, I made AABB vs AABB, Sphere vs Sphere, but couldn't get AABB vs Sphere to work correctly.

 

So I'm looking for code sample.

 

@imoogiBG: I have multiple rain drops per particles, so it need soft particles or the particles plane would appear intersecting the terrain/ground.




#5087292 Collision between particles (Planes) and Box

Posted by Medo3337 on 19 August 2013 - 07:27 AM

Currently, I would go for detecting collision between spheres (particles) and boxes (buildings)

 

Any idea how to detect collision between AABB and Sphere?




#5086835 Making a box move left to right over and over

Posted by Medo3337 on 17 August 2013 - 01:55 PM

Do you mean rotating the box?

 

If so, you can use D3DXMatrixRotationYawPitchRoll():

http://msdn.microsoft.com/en-us/library/windows/desktop/bb205361(v=vs.85).aspx




#5084679 Soft Particles

Posted by Medo3337 on 10 August 2013 - 06:54 AM

Up




#5083842 What do you think of this terrain?

Posted by Medo3337 on 07 August 2013 - 06:07 AM

Here you go, it finally stopped raining:

nr.png




#5082435 What do you think of this terrain?

Posted by Medo3337 on 02 August 2013 - 04:51 AM

I have been working for awhile on my own Game Engine with help from GameDev members and here is screenshots from what I have created:

 

Would appreciate your opinions! smile.png

 

1.png

 

2.png






PARTNERS