Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 4 of 4

Thread: 3d rendering - strange curved lines

Hybrid View

  1. #1
    Junior Member Newbie
    Join Date
    Dec 2012
    Posts
    5

    3d rendering - strange curved lines

    Like in topic. I am making voxel engine based on 16X256X16 tile arrays and encountered strange problem. Screenshots below:




    Rendering close to camera is very good, but while looking from a distance artifacts begin to appear. This artifacts are mostly composed of curved lines and rarely straight lines, but when I am moving camera away from the center in straight line something interesting happens:



    I don't know what is causing this problem. I already tried using mipmaps and anisotropic filtering, but nothing works (I am not even sure if this is texturing issue or something else). Does anyone have idea why this happens and how can I fix this?

  2. #2
    Senior Member OpenGL Pro
    Join Date
    Jan 2012
    Location
    Australia
    Posts
    1,106
    This is an image moire pattern. It cannot be eliminated only reduced using mipmaps and filtering.

  3. #3
    Junior Member Newbie yoyonel's Avatar
    Join Date
    Sep 2010
    Location
    Paris
    Posts
    23
    Yep it's a filtering problem.

    You need to understand what you do when you're rendering a 'pixel' with your voxel engine.

    In a few words, you need to consider a pixel like a mini frustum from the near plane of your camera and your world (voxel world).
    So when you render a pixel, you need to considerer the volumic shape of this pixel, and compute the "average" of the volume intersection (with your voxel grid).
    With this kind of consideration, you're transform your current (in your voxel engine, right now) pixel "point-sample" to a "area-sample" (frustum -> quad, (truncated) cone -> elipsoid, ...).

    Good luck ^^
    YoYOOoOo

  4. #4
    Junior Member Newbie
    Join Date
    Jul 2013
    Posts
    22
    glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR);

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •