POV-Ray : Newsgroups : povray.general : Image Maps question Server Time
2 Nov 2024 05:20:20 EDT (-0400)
  Image Maps question (Message 1 to 10 of 13)  
Goto Latest 10 Messages Next 3 Messages >>>
From: Mike Metheny
Subject: Image Maps question
Date: 4 May 1999 01:54:49
Message: <372e7d99.0@news.povray.org>
Okay, I have a glass bottle.  I want to put a logo on said bottle.  I use
the keyword 'once' in my imagemap, and position it as I want it, however
there are 2 images. . .one on the front and one on the back of the bottle.
What is the easiest way to remedy this?


--


Mike Metheny
lon### [at] vtedu
mik### [at] loneshepherdcom
http://www.loneshepherd.com/

"When one's words are no better than silence, one should keep silent."


Post a reply to this message

From: Ken
Subject: Re: Image Maps question
Date: 4 May 1999 02:06:19
Message: <372E7FD4.34C7E37F@pacbell.net>
Mike Metheny wrote:
> 
> Okay, I have a glass bottle.  I want to put a logo on said bottle.  I use
> the keyword 'once' in my imagemap, and position it as I want it, however
> there are 2 images. . .one on the front and one on the back of the bottle.
> What is the easiest way to remedy this?
> 
> --
> 
> Mike Metheny
> lon### [at] vtedu
> mik### [at] loneshepherdcom
> http://www.loneshepherd.com/

  Apply the image to a seperate object that has the same surface definitions
of the original but has only the surface area you wish to cover. Then apply
this hopefully very thin object as a decal or label to the original. It's
kinda cheesy but it works.

-- 
Ken Tyler

mailto://tylereng@pacbell.net


Post a reply to this message

From: Mike Metheny
Subject: Re: Image Maps question
Date: 4 May 1999 02:21:02
Message: <372e83be.0@news.povray.org>
<<Apply the image to a seperate object that has the same surface definitions
of the original but has only the surface area you wish to cover. Then apply
this hopefully very thin object as a decal or label to the original. It's
kinda cheesy but it works

Sigh. . .that's what I've done in the past but I was hoping there'd be an
easier way around this. . .oh well guess it's time to chop it up with CSG. .
.hopefully it won't look too bad. . .I'm just afraid it'll look funny since
it's glass.


--


Mike Metheny
lon### [at] vtedu
mik### [at] loneshepherdcom
http://www.loneshepherd.com/

"When one's words are no better than silence, one should keep silent."


Post a reply to this message

From: Ken
Subject: Re: Image Maps question
Date: 4 May 1999 02:25:16
Message: <372E8446.76B08227@pacbell.net>
Mike Metheny wrote:
> 
> <<Apply the image to a seperate object that has the same surface definitions
> of the original but has only the surface area you wish to cover. Then apply
> this hopefully very thin object as a decal or label to the original. It's
> kinda cheesy but it works
> 
> Sigh. . .that's what I've done in the past but I was hoping there'd be an
> easier way around this. . .oh well guess it's time to chop it up with CSG. .
> .hopefully it won't look too bad. . .I'm just afraid it'll look funny since
> it's glass.
> 
> --
> 
> Mike Metheny
> lon### [at] vtedu
> mik### [at] loneshepherdcom
> http://www.loneshepherd.com/
> 
> "When one's words are no better than silence, one should keep silent."

  My recommendation was of course based on the official version of Pov.
I think there might be an option in the UV pov patched version that
would let you go around the image map being treated as a solid texture.
I can't remember for sure so am hesitnt to say more at this time.

 Mr. Kopp if you read this would you care to confirm or deny this one way
or another ?

-- 
Ken Tyler

mailto://tylereng@pacbell.net


Post a reply to this message

From: Ron Parker
Subject: Re: Image Maps question
Date: 4 May 1999 10:23:27
Message: <372ef4cf.0@news.povray.org>
On Tue, 4 May 1999 00:54:45 -0400, Mike Metheny <lon### [at] vtedu> wrote:
>Okay, I have a glass bottle.  I want to put a logo on said bottle.  I use
>the keyword 'once' in my imagemap, and position it as I want it, however
>there are 2 images. . .one on the front and one on the back of the bottle.
>What is the easiest way to remedy this?

Try the radial texture.  

pigment {
  radial 
  pigment_map {
    [.5 image_map {... translate -.5}]
    [.5 color {rgbt 1}]
  }
  rotate, translate, and scale as necessary.
}


Post a reply to this message

From: Bob Hughes
Subject: Re: Image Maps question
Date: 4 May 1999 18:26:23
Message: <372F65F0.E0F4B85A@aol.com>
Sounds to me like you have used the default 'map_type 0' instead of a more
likely candidate for a bottle, 'map_type 2', cylindrical.
Except even doing it this way entails having a 256 color gif or png image
to use a transparent color for all parts not of the intended visible
region.
In other words, to put your "logo" onto a cylinder (keyword 'once' only
stops above and below tiling when map_type 2) you would place it into a
image with a pi:1 (3.1415:1) width to height ratio for use on a cylinder
that is 1 POV unit high and 2 in diameter (radius 1 unit). Ie. a image of
314x100 pixels would have proper aspect, paste the image you want to use
into that. Larger or smaller depending of course.
The background color of the image_map should be an unused color, one not
in the actual "logo" part. Then that palette index would be 'transmit 0,1'
for example, black (0) being invisible.
The usual scaling, rotating, translating would also no doubt be needed
within just the pigment statement to adjust afterward.


Mike Metheny wrote:
> 
> Okay, I have a glass bottle.  I want to put a logo on said bottle.  I use
> the keyword 'once' in my imagemap, and position it as I want it, however
> there are 2 images. . .one on the front and one on the back of the bottle.
> What is the easiest way to remedy this?
> 
> --
> 
> Mike Metheny
> lon### [at] vtedu
> mik### [at] loneshepherdcom
> http://www.loneshepherd.com/
> 
> "When one's words are no better than silence, one should keep silent."

-- 
 omniVERSE: beyond the universe
  http://members.aol.com/inversez/homepage.htm
 mailto://inversez@aol.com?Subject=PoV-News


Post a reply to this message

From: Mike Metheny
Subject: Re: Image Maps question
Date: 4 May 1999 19:00:43
Message: <372f6e0b.0@news.povray.org>
Well, I've tried all these options.  First I was using planar, which was
looking fine except for the double image.  Then I tried using a radial
texture, which was looking fine, except that it seemed there was a double
image, still front facing, of the logo on the *inside* of the bottle (since
the bottle is hollow and glass this is showing up) right behind the original
logo, looking like a shadowed effect.  So then I tried map_type 2, and
modified my bitmap to wrap around correctly.  It still appears that I am
getting a double image right behind the front logo however.  Maybe it's just
the lighting. . .or shadow. . .or something.  It's hard for me to do
extensive testing as long as it takes to render this stuff with the glass. .
.in any case I'll post the problematic image in .binaries shortly, soon as
it's done rendering and i convert it to a jpg.

Oh, and the bottle is currently from sPatch. . .if I ever do it in POV with
a complicated quadratic lathe, then I can just use planar, half the bottle,
and place another blank half against it.  This may leave a seam, but since
most bottles are cast in a mold, this seam is somewhat noticible on my
bottle that i'm modelling, so it'd just actually add a bit of realism maybe.
But for right now, my rough shape bottle is in sPatch.


--


Mike Metheny
lon### [at] vtedu
mik### [at] loneshepherdcom
http://www.loneshepherd.com/

"When one's words are no better than silence, one should keep silent."


Post a reply to this message

From: bankspad
Subject: Re: Image Maps question
Date: 5 May 1999 10:02:28
Message: <37303D51.CFFC9A66@pacbell.net>
I'll be honest, I'm venturing a guess and a question. I saw the image in
.images - it looks like the 'label' is reflecting off the glass interior. It
definetly looks like a reflection, yet since it doesn't seem to reflect off
the other side of the bottle I'm wondering if it is an interior reflection
rather than a surface one. My question (actually 2) is: Would changing the ior
have an affect on this if it is an interior reflection - and, would merging
(not union) or differencing the label and the bottle work to fix this?

KB-

Mike Metheny wrote:

> Okay, I have a glass bottle.  I want to put a logo on said bottle.  I use
> the keyword 'once' in my imagemap, and position it as I want it, however
> there are 2 images. . .one on the front and one on the back of the bottle.
> What is the easiest way to remedy this?
>
> --
>
> Mike Metheny
> lon### [at] vtedu
> mik### [at] loneshepherdcom
> http://www.loneshepherd.com/
>
> "When one's words are no better than silence, one should keep silent."


Post a reply to this message

From: Ron Parker
Subject: Re: Image Maps question
Date: 5 May 1999 11:41:32
Message: <3730589c.0@news.povray.org>
On Tue, 4 May 1999 18:00:42 -0400, Mike Metheny <lon### [at] vtedu> wrote:
>Then I tried using a radial
>texture, which was looking fine, except that it seemed there was a double
>image, still front facing, of the logo on the *inside* of the bottle (since
>the bottle is hollow and glass this is showing up) right behind the original
>logo, looking like a shadowed effect. 

Yep, you're right, you'll get that double image both with radial and with
map_type 2.  What you can do about it is use the wood or cylindrical patterns 
in a pigment map to control where the image map appears as a function of 
radius.  

If you have a bottle whose radius is ro and whose inner radius is ri, for
example, and if it's aligned with the Y axis and centered on the origin,
you would do this:

pigment {
  cylindrical pigment_map {
    [(ro+ri)/2/ro image_map {...}]
    [(ro+ri)/2/ro color rgbt 1]
  }
  scale <ro,1,ro>
}

Of course, if your bottle is curved significantly (e.g. has a narrow
'waist') in the area where the label will be applied, this will not 
work and you'll have to fall back on the 'decal' approach.


Post a reply to this message

From: Nathan Kopp
Subject: Re: Image Maps question
Date: 6 May 1999 01:37:58
Message: <37311C98.E8A8EA93@Kopp.com>
Ken wrote:
> 
>   My recommendation was of course based on the official version of Pov.
> I think there might be an option in the UV pov patched version that
> would let you go around the image map being treated as a solid texture.
> I can't remember for sure so am hesitnt to say more at this time.
> 
>  Mr. Kopp if you read this would you care to confirm or deny this one way
> or another ?
> 

This would be a good use for uv mapping.  But the uv coordinates of CSG
objects aren't that well defined. (Oh, it's not csg?  well then if sPatch
exported uv coordinates (which it does not) you could do some really fun
stuff).

I was going to suggest using wood or cylindrical with a pigment map, but
it looks like Ron already suggested that.  You mention that the bottle
is from sPatch.  Can't you just split it up in sPatch into two different
parts (outside and inside)?  The you could apply the map just to the
outside.

-Nathan


Post a reply to this message

Goto Latest 10 Messages Next 3 Messages >>>

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