POV-Ray : Newsgroups : povray.binaries.images : WIP: Sterograms of a cube! Server Time
14 Aug 2024 05:12:51 EDT (-0400)
  WIP: Sterograms of a cube! (Message 11 to 20 of 20)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: gimi
Subject: Re: Sterograms of a cube!
Date: 5 Jan 2003 11:36:06
Message: <3E185EE2.8040604@psico.ch>
hi Andrew, hi Jaap (this is your first name, i guess?)

Jaap Frank wrote:
> Your are mixing up two different Stereograms systems.
> 1. "magic eye pictures"
>     For this you must stare at the picture, that will say you look behind the
> picture.

[...]

> 2. Crossing eye method.
>     By crossing your eyes you look before the picture and your left eye now
>     looks at the right object and your right eye looks at the left object.

which is basically the same method to obtain the same effect,
the only difference is the "point of view" (POV.. duh ;), which
is either in front or behind the image. this difference in turn
results in the "image" (that you perceive) being flipped
back-to-front, for the reasons Jaap explained well already.

but there is another main difference you did not make clear:
there are (real) stereograms consisting of two separate images
to be viewed by either eye, and "Single Image [Random] Dot
Stereograms" (SI[R]DS), which, as the name implies, result
from a single picture - which contains information for both
of your eyes.

the pictures that Andrew posted, including the ascii example,
are SIDS, whereas Jaap posted a (double image) stereogram
combined in a single picture file..

i like your pictures very much, no matter if i have to cross
my eyes or look thru them ;) , and i was reminded of the many
experiments i have done. but i must admit that it did not occur
to me that i could also try this using povray..

i have written a SIRDS generator a long time ago (in AmigaBasic),
i think i don't have that .bas file anymore. but it is not very
hard to do. - if someone wants it, and if no "HOWTO" can be found
on google, i will be happy to re-write it in povray or so. ;)


> Tip: Put the identical objects at a considerable distance and use a camera
>         with an angle of about 6 - 8 degrees, else the effect is exaggerated.

so you approximate a parallel projection for either of the two
objects in order to avoid the "curvature" that andrew mentioned.
- did you try using orthographic projection instead?
i think that it would work very well. you just have to rotate
the two objects a little to get different angles for each eye;
then you can get both "crossing eye" and "magic eye" pictures,
as you call them, depending on which way you rotate them.


g.

-- 
mailto:gim### [at] psicoch
http://www.psico.ch/ 
http://psico.servehttp.com/


Post a reply to this message

From: Bill DeWitt
Subject: Re: Sterograms of a cube!
Date: 5 Jan 2003 13:15:53
Message: <3e187659$1@news.povray.org>
"Jaap Frank" <jjf### [at] xs4allnl> wrote :
>
> I've attached an animation of an alpha helix of 20 amino acids.

    Nice, if you watch it diverged eyed, it turns one way, crossed, it turns
the other.


Post a reply to this message

From: Jaap Frank
Subject: Re: Sterograms of a cube!
Date: 5 Jan 2003 13:36:55
Message: <3e187b47@news.povray.org>
"gimi" <gim### [at] psicoch> wrote in message news:3E1### [at] psicoch...

Hallo gimi,

> hi Andrew, hi Jaap (this is your first name, i guess?)

Yes, Jaap is my first name and Frank is my family name.
(Anne Frank is not family, there have been many Frank's
which were not related.)

> which is basically the same method to obtain the same effect,
> the only difference is the "point of view" (POV.. duh ;), which
> is either in front or behind the image. this difference in turn
> results in the "image" (that you perceive) being flipped
> back-to-front, for the reasons Jaap explained well already.
>
> but there is another main difference you did not make clear:
> there are (real) stereograms consisting of two separate images
> to be viewed by either eye, and "Single Image [Random] Dot
> Stereograms" (SI[R]DS), which, as the name implies, result
> from a single picture - which contains information for both
> of your eyes.

I think the SIRDS are the same principle as the red-green
double pictures that you have to view with a red and a green
glass for your eyes. Only the different colors are replaced
with a spaced random dot pattern and then superimposed.
Am I correct?

> the pictures that Andrew posted, including the ascii example,
> are SIDS, whereas Jaap posted a (double image) stereogram
> combined in a single picture file..
[..]
> so you approximate a parallel projection for either of the two
> objects in order to avoid the "curvature" that andrew mentioned.
> - did you try using orthographic projection instead?

It's one picture with two identical objects placed beside each
other without overlap and then viewed with one camera with a
small viewing angle. The camera is a normal perspective one.
You can do it yourself easily.
There's one drawback with this method. You can't make a
3D picture from inside an object, because the objects will
overlap then.

> i think that it would work very well. you just have to rotate
> the two objects a little to get different angles for each eye;
> then you can get both "crossing eye" and "magic eye" pictures,
> as you call them, depending on which way you rotate them.

If you use an orthographic camera, indeed you have to rotate
the objects to get the right configurations. I've never done
that, but it's another possibility. As long as you get the correct
differences it's oke. Maybe the 'perspective method' gives
you the normal distortions and the 'orthographic method'
will not give the right distortions for depth, but you can try
both with the same object and compare then.
If the orthographic camera doesn't work, you can rotate
the objects to make "magic eye" pictures.

Regards,

Jaap Frank


Post a reply to this message

From: Andrew Coppin
Subject: Re: Sterograms of a cube!
Date: 5 Jan 2003 14:19:57
Message: <3e18855d@news.povray.org>
> With some difficulty I can see this, but I prefer the double objects.
> That's much easier to hold steady.

Fair enough.

> > Mmm... I'm thinking animation 8-) Of course, question is, can you get
your
> > eyes to converge right before the animation is over? lol
>
> :)
> I've attached an animation of an alpha helix of 20 amino acids. It's
cyclic, so
> you have all the time to get it steady. It's made of two identical objects
> placed at a far distance and viewed with an small camera angle.
> What's your opinion about that?

Hey, that is actually pretty cool. Once again, my eyes won't converge that
far... In principle, if I could get the image the right size, I could put my
head real close to the screen and just look straight ahead I suppose. Tryed
it and I can't seem to manage it though!

> > Oooo dear me... I have to shrink the image down several times before I
can
> > cross my eyes far enough... hehehe
>
> Better sit back further from your display, because the resolution of
> your display may become to small to give all the details.

Yes, that would also make a lot of sense...

Btw, does anyone know the cost of VR headsets that display two seperate
images?

Thanks!
Andrew.


Post a reply to this message

From: Sir Charles W  Shults III
Subject: Re: Sterograms of a cube!
Date: 5 Jan 2003 15:45:24
Message: <3e189964$1@news.povray.org>
Cool!  The ends of your lysines are even spinning!

Cheers!

Chip Shults
My robotics, space and CGI web page - http://home.cfl.rr.com/aichip


Post a reply to this message

From: gimi
Subject: Re: Sterograms of a cube!
Date: 5 Jan 2003 15:59:24
Message: <3E189C89.4030304@psico.ch>
Jaap Frank wrote:
> I think the SIRDS are the same principle as the red-green
> double pictures that you have to view with a red and a green
> glass for your eyes. Only the different colors are replaced
> with a spaced random dot pattern and then superimposed.
> Am I correct?

nope. with rg-stereograms, you don't use the exact same
information for both eyes, but the results from the "filter
process", which makes red spots look black when seen through
the green glass and vice versa. - you do not look at a different
spot in the image with each eye!

[...]
>>so you approximate a parallel projection for either of the two
>>objects in order to avoid the "curvature" that andrew mentioned.
>>- did you try using orthographic projection instead?
> 
> It's one picture with two identical objects placed beside each
> other without overlap and then viewed with one camera with a
> small viewing angle. The camera is a normal perspective one.
> You can do it yourself easily.
> There's one drawback with this method. You can't make a
> 3D picture from inside an object, because the objects will
> overlap then.

i understood well how you do it! - but do you see how you
can make your "crossed-eye" into a "non-crossed-eye" stereo-
gram? - the angle from which an eye sees the object does
not have to be the result of it's position, but you can rotate
it instead, so that you don't have to cross your eyes..!

 > If you use an orthographic camera, indeed you have to rotate
 > the objects to get the right configurations. I've never done
 > that, but it's another possibility. As long as you get the correct
 > differences it's oke. Maybe the 'perspective method' gives
 > you the normal distortions and the 'orthographic method'
 > will not give the right distortions for depth, but you can try
 > both with the same object and compare then.
 > If the orthographic camera doesn't work, you can rotate
 > the objects to make "magic eye" pictures.

yes, the reason why i proposed the orthographic camera is
exactly that it will not distort the image if you choose
the "magic eye" variant.

but the orthographic camera will *only* work *if* you rotate
the object!

ok, maybe this shows what i mean (this is not intended to be
a stereogram of any kind - don't hurt your eyes! ;) :

       ----        ----
      /   /|      |\   \
      ---- |      | ----
      |  |/        \|  |
      ----          ----

this is how you do it - the same object looks different,
because one is to the left and thus seen from a different
angle as the one to the right. like when you look at the
object in real space. - you could cross your eyes and...
"hey! this looks like 3D!" (don't try it! ;)

note that the difference between both images is the result
of both their position and the kind of projection used
(like a normal camera does).


      ----           ----
     |\   \         /   /|
     | ----         ---- |
      \|  |         |  |/
       ----         ----

now if you rotate the left one counterclockwise and the right
one clockwise a little, you get the opposite effect. when
you use it as a stereogram, you won't have to cross your eyes,
but look "through" the image instead to get the effect.

this will look "wrong" when used with a "normal" camera,
however.

       ----       ----
       |  |       |  |
       ----       ----
       |  |       |  |
       ----       ----

and finally, this is how the objects would look with orthographic
projection but without any rotation; namely the exact same object
twice. - ok?


i guess we all agree now - so lets go and render some!! :D


g.

-- 
mailto:gim### [at] psicoch
http://www.psico.ch/ 
http://psico.servehttp.com/


Post a reply to this message

From: Ben T  Scheele
Subject: Re: Sterograms of a cube!
Date: 5 Jan 2003 20:54:46
Message: <3e18e1e6@news.povray.org>
That's cool.  How are those kinds of images different from the kind
you'd see in those stereo-opticon devices from a while back?
    Also, I found a program that allows you to create magic eye type images
if you have a texture file and a 3D image rendered as a depth map.  Does
anyone know how to render a scene that way?  I attached a sample of the
input and output.  The program is called Sisgen.

-Ben Scheele


Post a reply to this message


Attachments:
Download 'DOLDEMO.jpg' (10 KB) Download 'train.jpg' (36 KB) Download 'TREEPT85.jpg' (4 KB)

Preview of image 'DOLDEMO.jpg'
DOLDEMO.jpg

Preview of image 'train.jpg'
train.jpg

Preview of image 'TREEPT85.jpg'
TREEPT85.jpg


 

From: hughes, b 
Subject: Re: Sterograms of a cube!
Date: 6 Jan 2003 01:44:20
Message: <3e1925c4@news.povray.org>
"Ben T. Scheele" <sch### [at] tcumnedu> wrote in message
news:3e18e1e6@news.povray.org...
>     That's cool.  How are those kinds of images different from the kind
> you'd see in those stereo-opticon devices from a while back?
>     Also, I found a program that allows you to create magic eye type
images
> if you have a texture file and a 3D image rendered as a depth map.  Does
> anyone know how to render a scene that way?  I attached a sample of the
> input and output.  The program is called Sisgen.

The difference is probably in just that the effect is done by repetition of
an identical object which is shifted a little from each other. In the case
of the cubes they are rotated, a lone pair of them would be like a
stereo-optic photo.

You can see a somewhat 3D plus 2D effect in any repeated pattern, such as
wallpaper, without there being any shifts.

The way you'd do a depth map in POV-Ray 3.5 is by applying a universal
pigment gradient to the scene objects that goes from rgb 1 to rgb 0 with
only ambient 1 finish and no light sources. The orientation being aligned
with the camera. It has been done before. In fact, MegaPOV 0.7 has a feature
to make it a little easier except you still need to know the nearest and
farthest points of the scene objects. In 3.5 there is min_extent and
max_extent to find a measure of a unioned scene by extracting one of the
axes, unfortunately it isn't accurate for complex objects and you'd still
have to do some orientation to the camera.

Rune Johannsen has a tutorial on this
http://runevision.com/graphics/stereo/depthmap/depthmap.asp


Post a reply to this message

From: master of psico
Subject: Re: Sterograms of a cube!
Date: 7 Jan 2003 12:21:50
Message: <3E1B0CA8.5070209@psico.ch>
hi

hughes, b. wrote:
 > "Ben T. Scheele" <sch### [at] tcumnedu> wrote in message
 > news:3e18e1e6@news.povray.org...
 >>    That's cool.  How are those kinds of images different from
 >>the kind you'd see in those stereo-opticon devices from a while back?
 >>    Also, I found a program that allows you to create magic eye type
 >>images if you have a texture file and a 3D image rendered as a depth 
 >>map.
 >>Does anyone know how to render a scene that way?  I attached a sample 
 >>of the input and output.  The program is called Sisgen.

i don't know the devices mentioned. - do they use one or two images?
what are they doing, anyway?

sisgen is for "Single Image Stereogram GENnerator", right?

 > The difference is probably in just that the effect is done by
 > repetition of an identical object which is shifted a little from
 > each other. In the case of the cubes they are rotated, a lone
 > pair of them would be like a stereo-optic photo.

the difference from what?

anyway, to get the same results as with sisgen, or most "magic
eye"-pictures, only a few additions have to be made to the perl
code i have posted: you would have to replace the call to "rand()"
with something that picks the next color value from your texture
instead. - this could be a little tricky however, because this
texture can not just be "shifted" or "rotated" as in the cube
example. the current color actually depends on the depth map and
some additional parameters like the eye distance...

if you look at one of these magic-eye pictures, you will see
that the texture is getting more distorted towards one side of
the image. this is because of the way the algorithm works.

from the perspective of creating stereoscopic pictures, this
of course is a completely different story than just showing
the same object from two different angles...

if anyone is insterested, i'll post another piece of perl
code which is able to use "textures" to create SI[D]S.
i'm thinking of doing it with ascii first, so you could
maybe use your name as a texture.. ;)

- in any case, this has been done before, too, so you can probably
find the solution on google as well. ;)

 > You can see a somewhat 3D plus 2D effect in any repeated pattern,
 > such as wallpaper, without there being any shifts.

hmm... i don't quite get what you mean here. - you really mean
you see 3D effects when looking at your wall and crossing your
eyes? :)

 > The way you'd do a depth map in POV-Ray 3.5 is by applying a universal
 > pigment gradient to the scene objects that goes from rgb 1 to rgb 0
 > with only ambient 1 finish and no light sources. The orientation being
 > aligned with the camera. It has been done before. In fact, MegaPOV 0.7
 > has a feature to make it a little easier except you still need to know
 > the nearest and farthest points of the scene objects. In 3.5 there is
 > min_extent and max_extent to find a measure of a unioned scene by
 > extracting one of the axes, unfortunately it isn't accurate for
 > complex objects and you'd still have to do some orientation to the
 > camera.
 >
 > Rune Johannsen has a tutorial on this
 > http://runevision.com/graphics/stereo/depthmap/depthmap.asp

thanks! i knew there must be some simple way to do it!
and this sounds *brilliantly* simple!! :)


g.


Post a reply to this message

From: hughes, b 
Subject: Re: Sterograms of a cube!
Date: 7 Jan 2003 15:43:03
Message: <3e1b3bd7@news.povray.org>
"master of psico" <roo### [at] psicoch> wrote in message
news:3E1### [at] psicoch...
>
> hughes, b. wrote:
>
> i don't know the devices mentioned. - do they use one or two images?
> what are they doing, anyway?

I believe Ben T. Scheele was talking of those stereoscopes which were, and
are, used to see stereo pair photos. Or like the ViewMaster which used a
wheel of images. That kind of thing in general.

> sisgen is for "Single Image Stereogram GENnerator", right?

Yes, apparently so  :-)

>  > The difference is probably in just that the effect is done by
>  > repetition of an identical object which is shifted a little from
>  > each other. In the case of the cubes they are rotated, a lone
>  > pair of them would be like a stereo-optic photo.
>
> the difference from what?

From single image stereograms or random dot stereograms or other such
non-paired 3D images. Those cube renders are similar to stereo pairs but the
subject object has been repeated many times across the whole image abd it
isn't of just two views unlike the left/right eye kind.

> anyway, to get the same results as with sisgen, or most "magic
> eye"-pictures, only a few additions have to be made to the perl
> code i have posted: you would have to replace the call to "rand()"
> with something that picks the next color value from your texture
> instead. - this could be a little tricky however, because this
> texture can not just be "shifted" or "rotated" as in the cube
> example. the current color actually depends on the depth map and
> some additional parameters like the eye distance...
---snip---
> if anyone is insterested, i'll post another piece of perl
> code which is able to use "textures" to create SI[D]S.
> i'm thinking of doing it with ascii first, so you could
> maybe use your name as a texture.. ;)

Sounds interesting, but I failed to find where you might have already posted
anything of this. And I never used Perl so this is probably lost on me.
Guess others can follow okay.

>  > You can see a somewhat 3D plus 2D effect in any repeated pattern,
>  > such as wallpaper, without there being any shifts.
>
> hmm... i don't quite get what you mean here. - you really mean
> you see 3D effects when looking at your wall and crossing your
> eyes? :)

Yes. If you look at any repeating pattern cross-eyed or parallel-eyed it
will separate from the background (inbetween spaces of pattern). So the
effect is that of a two layer 3D scene, or more descriptively it looks like
a window with decals stuck on it with a wall or infinite space behind them.

--
Farewell,
Bob


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.