• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            牽著老婆滿街逛

            嚴(yán)以律己,寬以待人. 三思而后行.
            GMail/GTalk: yanglinbo#google.com;
            MSN/Email: tx7do#yahoo.com.cn;
            QQ: 3 0 3 3 9 6 9 2 0 .

            關(guān)于Sweep and Prune 算法

            在第一階段的檢測(cè)(BroadPhase)中所需要的算法就是Sweep and Prune,因?yàn)閺奈唇佑|過(guò)此類(lèi)的東西,所以不知道到底是個(gè)什么東西,今天終于找到具體資料了,一看,暈倒掉了.原來(lái)就是<游戲編程精粹2>里面所提及到的 逐維遞歸分組法...
            貌似如果有人搜索相關(guān)詞匯是能夠搜索到我的blog的,特別留下此文以防止有哥們走我同樣的彎路了...


            順便放一個(gè)英文東西:
            來(lái)自于:http://parallel.vub.ac.be/documentation/pvm/Example/Marc_Ramaekers/node3.html
            Sweep and Prune
            Given a number N of objects, O(N2) object pairs have to be checked for collision. In general, the objects in most of the pairs aren't even close to each other so we should be able to eliminate them quickly. To do this we use a technique called Sweep and Prune ([CLMP95]). In this section I will briefly introduce this technique.

            To determine whether two objects are close enough to potentially collide, the Sweep and Prune checks whether the axis aligned bounding boxes of the respective objects overlap. If they do, further investigation is necessary. If not, the objects can't possibly collide and the algorithm can move on. To determine whether two bounding boxes overlap, the algorithm reduces the 3D problem to three simpler 1D problems. It does so by determining the intervals occupied by the bounding volume along each of the x,y and z axes. If and only if the intervals of two bounding volumes overlap in all of the three dimensions, the objects corresponding to these bounding volumes must overlap. To determine which intervals of the objects along an axis overlap, the list of the intervals is sorted. Normally, using quick-sort, this would be an $O(N \log N)$ process. However, by exploiting frame coherence (the similarity between situations in two subsequent frames) we can sort the lists in an expected (O(N), using insertion sort.

            Another difficult part in the Sweep and Prune approach is the maintenance of the bounding volume. If the objects in the scene move or rotate, the previously calculated bounding boxes are invalid. It is important to be able to update the boxes as quickly as possible. Again, we can do this by exploiting frame coherence.

            The algorithm's performance is of course dependent on the application and the typical situations that occur in that application. Many variations exists, such as reducing the overlap problem by only 1 dimension and using a rectangle intersection test. It is also possible to choose other types of bounding volumes that might be faster to update but produce a less accurate approximation of the object.

            posted on 2008-01-15 15:35 楊粼波 閱讀(4184) 評(píng)論(2)  編輯 收藏 引用

            評(píng)論

            # re: 關(guān)于Sweep and Prune 算法 2010-01-18 15:44 狂沙

            我看到了,感謝!  回復(fù)  更多評(píng)論   

            # re: 關(guān)于Sweep and Prune 算法 2011-06-26 18:55 tankin

            @狂沙
            感謝,希望看到更多有意義內(nèi)容的blog  回復(fù)  更多評(píng)論   


            只有注冊(cè)用戶(hù)登錄后才能發(fā)表評(píng)論。
            網(wǎng)站導(dǎo)航: 博客園   IT新聞   BlogJava   博問(wèn)   Chat2DB   管理


            久久天天躁狠狠躁夜夜96流白浆| 精品水蜜桃久久久久久久| 偷窥少妇久久久久久久久| 人妻中文久久久久| 一本综合久久国产二区| 伊人久久综合无码成人网| 久久91亚洲人成电影网站| 久久久免费观成人影院| 久久影院综合精品| 国产精品亚洲综合专区片高清久久久| 开心久久婷婷综合中文字幕| 人妻无码αv中文字幕久久| 国内精品久久久久久久久| 精品国产日韩久久亚洲| 日韩欧美亚洲综合久久影院d3| 久久久久久无码国产精品中文字幕 | 国产精品久久久久久久app| 99久久无码一区人妻a黑| 久久这里的只有是精品23| 久久精品国产亚洲AV无码麻豆| 欧美久久亚洲精品| 久久国产精品-久久精品| 久久精品卫校国产小美女| 久久久黄片| 91精品国产91久久久久久| 日韩精品无码久久久久久| 一日本道伊人久久综合影| 青青草国产精品久久久久| 国内精品久久久久久久97牛牛| 国内精品伊人久久久久妇| 人妻少妇精品久久| 人妻系列无码专区久久五月天| 久久精品无码一区二区三区日韩| AV无码久久久久不卡蜜桃| 久久久久女人精品毛片| 久久久久久国产精品无码下载| 国内精品久久久久久久久| 国产精品伊人久久伊人电影| 国产精品美女久久久久网| 欧美大香线蕉线伊人久久| 人妻精品久久无码专区精东影业|