Advertisement

Weird artefact

Started by September 29, 2003 04:49 PM
3 comments, last by Crispy 21 years, 5 months ago
Firstly, I''m sorry I can''t provide a screenshot, which would help a great deal, so I''ll try to convey the problem using my not so good description skills. Suppose you were rendering a torus which consisted of different length segments (firmly connected to form one long torus). Here''s a cross-section of it:

_____________________
_________|____|___|__
The vertical lines are imaginary - they are in no way rendered. This is where the problem appears - when blending the entire torus, while viewed from outside, the vertical lines seem to exist. They appear in the form of slabs that cap the sections, but are not visible when the camera looks straight down the torus. That is, if you take a pipe, imagine that it''s transparent and look at it from the side, you can see oval slabs (also transparent, but clearly visible) where the sections meet. Adversely, if you look through the torus as if using it as a telescope, there is nothing to block the view. I''m pretty confident this isn''t a rendering or simple math error. Alphatesting is disabled (even though I don''t know how it could even affect the scene in some way similar to this). Enabling cullface seems to get rid of the slabs where there is no visible back side - enabling cullface, however, is not an option for me. Fog is disabled, no TexGen functions have been called, depth testing is lequal and I''m out of ideas. Can this be a stencil buffer problem even though I fail to see how? I''m rendering the torus as a set of triangles so that the layout looks like this:

  top
........
7 8 .. 9
4 5 .. 6 
1 2 .. 3
........
 bottom
It wraps around the edges (that is, 7 connects to 9, 4 to 6, 1 to 3, etc) and the triangles are drawn very simply, following the pattern: 125 + 541. Any suggestions? Cheers
"Literally, it means that Bob is everything you can think of, but not dead; i.e., Bob is a purple-spotted, yellow-striped bumblebee/dragon/pterodactyl hybrid with a voracious addiction to Twix candy bars, but not dead."- kSquared
CAn''t say without a screenshot, if you can''t post it then mail it to me, or get a free website over at geocities or something.

IF your auto generating this "torus" then some code would be nice to.

---------------------------------
For an overdose of l33tness, flashbang.nu
Advertisement
Thanks for replying, but I came up with an ingenious, but totally unprofessional (or overy professional, depends on how you look at it) hack. The weird discs go away if I swap the x/z and y axis when rendering *g* (that is, render by column as opposed to by row).

And as for the screenshot - the problems were technical because I was actually helping out a friend of mine and he hasn''t written a screenshot dumper yet. I dunno why he refused to use my code. Anyway - problem solved
"Literally, it means that Bob is everything you can think of, but not dead; i.e., Bob is a purple-spotted, yellow-striped bumblebee/dragon/pterodactyl hybrid with a voracious addiction to Twix candy bars, but not dead."- kSquared
Why bother using a screenshot dumper? I find the print screen key to work fine...
-~-The Cow of Darkness-~-
Heh... damn...
"Literally, it means that Bob is everything you can think of, but not dead; i.e., Bob is a purple-spotted, yellow-striped bumblebee/dragon/pterodactyl hybrid with a voracious addiction to Twix candy bars, but not dead."- kSquared

This topic is closed to new replies.

Advertisement