Menu

#2 Problem with ShadowCasting FOV algorithm

open-postponed
nobody
None
3
2008-06-03
2008-05-18
No

Hi.

I'm trying your library and I see something strange:

Look this map;
####################
####### #
####### #### # #
###### ### # #
## @ ### # #
## ### ### ### # #
## #### ## ### # #
# ### ## ##### # #
####################

If I use Precise Permissive FOV algorithm, I get:
?????????#??????????
???????? ???????????
??????? ##??????????
?##### #??????????
?# @ #??????????
?# ### #??????????
??????? ##??????????
????????#???????????
????????????????????
I think this is a good result because you see the same above and below (in the room at the rigth of @).

But if I use ShadowCasting, I get this result:
????????????????????
????????????????????
????????##??????????
?##### #??????????
?# @ #??????????
?# ###??????????????
????????????????????
????????????????????
I don't know why I can see more room above than below. I think is a symmetric scenario. So I should see the same (like with Precise Permisive)

Could you throw some light on this issue.

Thanks a lot.

Discussion

  • Sid D

    Sid D - 2008-06-03

    Logged In: YES
    user_id=1005608
    Originator: NO

    Hi,

    This phenomenon is very likely created by the fact that shadowcasting starts at 0 degrees and ends at 359.9.

    I am not giving Shadowcasting a high priority since precise permissive works so much better and you can do everything ( cone, LOS ) with it. I will try to fix this when I have the time.

     
  • Sid D

    Sid D - 2008-06-03
    • priority: 5 --> 3
    • status: open --> open-postponed
     
  • Alejandro Pérez García

    Logged In: YES
    user_id=1729240
    Originator: YES

    ok, thanks for your clear answer.

    for now precise permissive is enough for me (really it's great ;)

     

Log in to post a comment.

MongoDB Logo MongoDB