| 2962 | } |
| 2963 | |
| 2964 | bool NpScene::fetchQueries(bool block) |
| 2965 | { |
| 2966 | if(!mSceneQueriesUpdateRunning) |
| 2967 | { |
| 2968 | //fetchSceneQueries doesn't get called |
| 2969 | Ps::getFoundation().error(PxErrorCode::eINVALID_OPERATION, __FILE__, __LINE__, |
| 2970 | "PxScene::fetchQueries: fetchQueries() called illegally! It must be called after sceneQueriesUpdate()"); |
| 2971 | return false; |
| 2972 | } |
| 2973 | |
| 2974 | if(!checkSceneQueriesInternal(block)) |
| 2975 | return false; |
| 2976 | |
| 2977 | { |
| 2978 | PX_SIMD_GUARD; |
| 2979 | |
| 2980 | NP_WRITE_CHECK(this); |
| 2981 | |
| 2982 | // we use cross thread profile here, to show the event in cross thread view |
| 2983 | // PT: TODO: why do we want to show it in the cross thread view? |
| 2984 | PX_PROFILE_START_CROSSTHREAD("Basic.fetchQueries", getContextId()); |
| 2985 | |
| 2986 | // flush updates and commit if work is done |
| 2987 | mSQManager.flushUpdates(); |
| 2988 | |
| 2989 | PX_PROFILE_STOP_CROSSTHREAD("Basic.fetchQueries", getContextId()); |
| 2990 | PX_PROFILE_STOP_CROSSTHREAD("Basic.sceneQueriesUpdate", getContextId()); |
| 2991 | |
| 2992 | mSceneQueriesDone.reset(); |
| 2993 | mSceneQueriesUpdateRunning = false; |
| 2994 | } |
| 2995 | return true; |
| 2996 | } |
| 2997 | |
| 2998 | void NpScene::frameEnd() |
| 2999 | { |
nothing calls this directly
no test coverage detected