0
$\begingroup$

Rosanswers logo

Using gazebo, I often get noticable artifacts which I strongly suspect to be related to Z-Fighting due to the far clip plane being unnecessary far away (or the near clip plane being close). How can I set the near and far clip planes for the visualization window? Searching for combinations of "gazebo, z-buffer, clip planes, near, far, z-fighting" I didn't find an answer.

/edit: The flickering effect is well visible in this video. Note that the default gazebo visualization camera exhibits severe flickering, while the camera sensor plugin based view doesn't show the effect at all (most likely because it has more reasonable near/far clip planes).

/Update I made a video of the pr2_gazebo wg world scenario started using

roslaunch pr2_gazebo pr2_wg_world.launch

As is easily visible, the static geometry is flickering severely.

/Update: Some images that demonstrate the problem:

View looking ok:

image description

Now, if I just rotate the camera very slightly (no translation), I get very visible rendering artifacts:

image description

Different camera location, same story (even if the first view already has some parts clipping through the walls, which they definitely shouldn't geometry-wise): image description

After slight camera rotation:

image description

/edit: With increasing distance, one can get lucky and get an acceptable view: image description

but slight rotation also changes this to have severe artifacts: image description

This happens all the time on my machine and leads to severe flickering as soon as I move the camera around. The machine is a 64Bit Natty system with ROS electric from .debs with a nvidia GPU.

/edit: I created ticket 42 on this at the gazebo trac here.


Originally posted by Stefan Kohlbrecher on ROS Answers with karma: 24361 on 2012-01-05

Post score: 2

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

It turns out the problem is that the user camera (gui view) has too large of a range for near/far clip at 0.001 to 4000 meters. By reducing the range this strange z-fighting effect is reduced. The fixes should go out with the next electric release.


Originally posted by hsu with karma: 5780 on 2012-03-21

This answer was ACCEPTED on the original site

Post score: 1

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.