UV seams visible at distance with texpaint even with 8 px bleed & 0.1 filter size #44728

Closed
opened 2015-05-16 15:22:23 +02:00 by WK Bong · 11 comments

System Information
Win7 64bit GTX 560ti
Win8 64bit GTX 980

Blender Version
Broken: 2.74.5 05c4c24

Short description of error
Today 1 beginner blenderhead brought the problem to my attention.
This file is extreme case where every edge is marked with seam. (lazy UV-ing)
This bug is very old, noticed it in 2.67 even.

In texpaint, with bleed of 8 px, UV seams appear as white lines with distance (camera to seams).
Visible in viewport (perspective, ortho) and in BI (perspective, ortho).
note: UV islands have enough gaps.
UV_gap_problem4.png
image sampling > Filter size (0.1) didn't help with more distance.
UV_gap_problem5.png

Exact steps for others to reproduce the error
SeamBug.blend

  1. See flickering white lines on viewport.
  2. Add more objects with array mod.
  3. Then render.
  4. You'll see seams with distance.

Only when you paint the whole texture in 1 color the seam will disappear.

**System Information** Win7 64bit GTX 560ti Win8 64bit GTX 980 **Blender Version** Broken: 2.74.5 05c4c24 **Short description of error** Today 1 beginner blenderhead brought the problem to my attention. This file is extreme case where every edge is marked with seam. (lazy UV-ing) This bug is very old, noticed it in 2.67 even. In texpaint, with bleed of 8 px, UV seams appear as white lines with distance (camera to seams). Visible in viewport (perspective, ortho) and in BI (perspective, ortho). **note**: UV islands have enough gaps. ![UV_gap_problem4.png](https://archive.blender.org/developer/F175473/UV_gap_problem4.png) image sampling > Filter size (0.1) didn't help with more distance. ![UV_gap_problem5.png](https://archive.blender.org/developer/F175483/UV_gap_problem5.png) **Exact steps for others to reproduce the error** [SeamBug.blend](https://archive.blender.org/developer/F175476/SeamBug.blend) 1. See flickering white lines on viewport. 2. Add more objects with array mod. 3. Then render. 4. You'll see seams with distance. Only when you paint the whole texture in 1 color the seam will disappear.
Author

Changed status to: 'Open'

Changed status to: 'Open'
Author

Added subscriber: @WeeKwongBong

Added subscriber: @WeeKwongBong

Added subscriber: @brecht

Added subscriber: @brecht

This is a classic problem with UV atlases and filtering in renderers.

In Blender Internal you can avoid the white lines by disabling mip maps and setting the filter size low enough. You then get aliasing instead though, and can't get rid of it because Blender Internal will only sample the texture once per pixel.

In Cycles such aliasing is solved by using more AA samples which will sample the texture multiple times per pixel, but that's slower to render. As far as I know that's the only solution to both avoid the bleeding and aliasing problems, so Blender Internal would need to get some way to sample textures multiple times per pixel to solve this.

This is a classic problem with UV atlases and filtering in renderers. In Blender Internal you can avoid the white lines by disabling mip maps and setting the filter size low enough. You then get aliasing instead though, and can't get rid of it because Blender Internal will only sample the texture once per pixel. In Cycles such aliasing is solved by using more AA samples which will sample the texture multiple times per pixel, but that's slower to render. As far as I know that's the only solution to both avoid the bleeding and aliasing problems, so Blender Internal would need to get some way to sample textures multiple times per pixel to solve this.
Author

I found a temporary fix for this on BI.
Turn ON transparency on Material & Alpha influence on texture.
(something to investigate there)

But still, it looks pretty bad on viewport & BGE.
Since we are going to have better GLSL renderer, I think we should look into solving this properly.

I found a temporary fix for this on BI. **Turn ON transparency on Material & Alpha influence on texture.** (something to investigate there) But still, it looks pretty bad on viewport & BGE. Since we are going to have better GLSL renderer, I think we should look into solving this properly.

I don't think enabling alpha really solves the problem. In the attached .blend file the space between the UV islands has alpha 0, and enabling alpha makes it black, which in this test file happens to be the same color as the UV islands themselves. But if the islands have a different color the issue shows up again.

If you want to solve this fully for GLSL, I guess you should look into limiting the mipmap levels to a certain number (e.g. 3 for pixel bleed 8). Then you get some aliasing which you can solve with multisample if necessary. Although I would expect the solution typically used in games to be just bleeding more than 8 pixels.

I don't think enabling alpha really solves the problem. In the attached .blend file the space between the UV islands has alpha 0, and enabling alpha makes it black, which in this test file happens to be the same color as the UV islands themselves. But if the islands have a different color the issue shows up again. If you want to solve this fully for GLSL, I guess you should look into limiting the mipmap levels to a certain number (e.g. 3 for pixel bleed 8). Then you get some aliasing which you can solve with multisample if necessary. Although I would expect the solution typically used in games to be just bleeding more than 8 pixels.
Author

More renders of the case.
UV gap problem1.png
UV gap problem.png
UV gap problem6.png
all rendered in BI

More renders of the case. ![UV gap problem1.png](https://archive.blender.org/developer/F178692/UV_gap_problem1.png) ![UV gap problem.png](https://archive.blender.org/developer/F178694/UV_gap_problem.png) ![UV gap problem6.png](https://archive.blender.org/developer/F178696/UV_gap_problem6.png) all rendered in BI

Added subscriber: @Sergey

Added subscriber: @Sergey

Changed status from 'Open' to: 'Archived'

Changed status from 'Open' to: 'Archived'
Sergey Sharybin self-assigned this 2015-05-26 12:03:29 +02:00

Disabled alpha is indeed just a co-incident because your texture is black.

In Cycles we only have mipmaps only when using OSL backend, so this issue is not such a trouble there. And surely we can improve BI to support maximum mipmap level or to do more AA samples, but this is more a TODO item.

So thanks for the report, but archiving it now. Possible workarounds @brecht already mentioned here.

Disabled alpha is indeed just a co-incident because your texture is black. In Cycles we only have mipmaps only when using OSL backend, so this issue is not such a trouble there. And surely we can improve BI to support maximum mipmap level or to do more AA samples, but this is more a TODO item. So thanks for the report, but archiving it now. Possible workarounds @brecht already mentioned here.
Author

@Sergey

"surely we can improve BI to support maximum mipmap level or to do more AA samples"

How that works? I'm curious.

@Sergey "surely we can improve BI to support maximum mipmap level or to do more AA samples" How that works? I'm curious.
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#44728
No description provided.