Collision Detection Problems
Collision Detection Problems
Collision Detection Problems
Collision Detection Problems
Collision Detection Problems
Collision Detection Problems Collision Detection Problems Collision Detection Problems Collision Detection Problems Collision Detection Problems Collision Detection Problems Collision Detection Problems Collision Detection Problems
Collision Detection Problems Collision Detection Problems
Collision Detection Problems
Go Back  Xtreme Visual Basic Talk > > > > Collision Detection Problems


Reply
 
Thread Tools Display Modes
  #1  
Old 04-05-2005, 09:19 AM
DecemberChild DecemberChild is offline
Newcomer
 
Join Date: Dec 2003
Location: Scania, Sweden
Posts: 16
Default Collision Detection Problems


I've just created a first person camera in D3D9 and I'm currently working on the collision detection. I have managed to detect the collision itself, but I'm having trouble making collisions look good.

When checking if any collisions occured, this is the algorithm that is being used:

----------------------------------------
If no collision is detected then:
oldPosition = cam.currentPosition

if any collision is detected then:
cam.currentPosition = oldPosition
----------------------------------------

... Where oldPosition and cam.currentPosition are two 3D Vectors. I thought this would work good since oldPosition will be the latest point where no collision occured. So if any collision is detected, then the camera's position will change to that point.

The problem is, that even if the distance between oldPosition and cam.currentPosition is very small, it's still very noticable. When colliding, everything looks like crap. It gets very blurry because of the position that keeps changing.

Does anyone have any good ideas of how I could make this different? I'm not sure how it's usually done. I thought I had a good idea with the algorithm above, but no...

Any help will be very appreciated.
Thanks in advance, Eric.
Reply With Quote
  #2  
Old 04-06-2005, 01:08 AM
ardman ardman is offline
Contributor
 
Join Date: Jan 2002
Posts: 126
Default

How exactly are you doing your collision detection? Do you have a code snippet you could post so we can get more of an idea on exactly how you are processing your collision detection.
__________________
Cheers
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Advertisement:





Free Publications
The ASP.NET 2.0 Anthology
101 Essential Tips, Tricks & Hacks - Free 156 Page Preview. Learn the most practical features and best approaches for ASP.NET.
subscribe
Programmers Heaven C# School Book -Free 338 Page eBook
The Programmers Heaven C# School book covers the .NET framework and the C# language.
subscribe
Build Your Own ASP.NET 3.5 Web Site Using C# & VB, 3rd Edition - Free 219 Page Preview!
This comprehensive step-by-step guide will help get your database-driven ASP.NET web site up and running in no time..
subscribe
Collision Detection Problems
Collision Detection Problems
Collision Detection Problems Collision Detection Problems
Collision Detection Problems
Collision Detection Problems
Collision Detection Problems Collision Detection Problems Collision Detection Problems Collision Detection Problems Collision Detection Problems Collision Detection Problems Collision Detection Problems
Collision Detection Problems
Collision Detection Problems
 
Collision Detection Problems
Collision Detection Problems
 
-->