POV-Ray : Newsgroups : povray.binaries.utilities : Rebuilt pose2pov : Re: Rebuilt pose2pov Server Time
28 Sep 2024 18:59:29 EDT (-0400)
  Re: Rebuilt pose2pov  
From: Cliff Bowman
Date: 22 Aug 2000 14:37:46
Message: <39a2c87a@news.povray.org>
"Christophe Bouffartigue" <Chr### [at] nanterremarellifr>
wrote in message news:39A25B91.889955E5@nanterre.marelli.fr...
> Cliff Bowman wrote:
> >
> >
> > I haven't uploaded the update due to assuming there was a lack of
interest,
> > but if people want my little Visual Basic 5 effort then it's free.
Limited,
> > but free.
>
> Yes, I want... ;)
>
> I often use OBJuvPOV in conjonction with UVMapper, and it works
> perfectly for me
> (except that the camera and light location are generated with ','
> instead of '.'
> in the numbers (am I clear ??)...)
>


Possibly. It attempts to calculate reasonable light and camera positions
based on the model. so, for example, for the Poser4 lo-resolution casual
female (with no hair) exported as box.obj (for reasons too silly to go into)
it produces the following .POV file (but without the annotations which I've
added manually).

In addition I should mention that to select mesh2 format you should first
select "Tools...Options...POV Export" and select uvPOV mesh2. That will
become the default from thereon in. I've had trouble with the Trimap version
if including more than 1 mesh, or moving the mesh, so I haven't even tested
that option in this latest version (however last time I tested it with just
1 copy of an untranslated mesh mesh it worked beautifully with Chris
Colefax's Trimap mesh macro).

#version unofficial MegaPOV 0.5; // Quick hack added to produce this,
regardless of export type. Naughty of me, but I'm concentrating on a C++
version called "OBJuvMOD".
//First off we get the extents of the .OBJ file.
#declare OBJuvPOVmaxX =  .317443;
#declare OBJuvPOVminX = -.31757;
#declare OBJuvPOVmaxY =  .700764;
#declare OBJuvPOVminY = -.00158505;
#declare OBJuvPOVmaxZ =  .0488173;
#declare OBJuvPOVminZ = -.0713547;
//Then the camera position. Is this what you mean about using "."'s?
camera {
    location <-6.35000000000496E-05 , 0.349589475 ,-1.4159668 >
    look_at <-6.35000000000496E-05 , 0.349589475 ,-0.0112687 >
}

//Again, light source positions are rather daft.
light_source { <-1.58785 , 3.50382 ,-0.3567735 > rgb<1,1,1>}
light_source { < 1.587215 , 3.50382 ,-0.3567735 > rgb<1,1,1>}
background {rgb<0.5,0.5,0.5>}
//Now I set up a default texture - obviously you can (indeed should) change
// the bitmap to the one you wish to use as the default texture (e.g. the
texture
// file for a low-res casual female in this example).
#declare OBJuvPOV_Texture = texture
{
    pigment
    {
        image_map
        {
            tga "OBJuvPOV.tga"
        }
    }
}
//Each texture thereafter is, by default, simply a copy of the "default"
one. Change the
// definition of the texture to something else for any halfway decent model
// (for example, to set a different finish to eyes, nails, hair etc. -
and/or different UV
// texture bitmaps).
// The name of each texture is calculated from the texture/material name in
the .OBJ
// file (appaended to "OBJuvPOV_Texture_OBJuvPOV" because I couldn't
imageine
// THAT as *ever* being a name used in a real model).

#declare OBJuvPOV_Texture_OBJuvPOVcolor2 = texture {OBJuvPOV_Texture}
#declare OBJuvPOV_Texture_OBJuvPOVcolor1 = texture {OBJuvPOV_Texture}
#declare OBJuvPOV_Texture_OBJuvPOVcolor5 = texture {OBJuvPOV_Texture}
#declare OBJuvPOV_Texture_OBJuvPOVcolor3 = texture {OBJuvPOV_Texture}
#declare OBJuvPOV_Texture_OBJuvPOVcolor4 = texture {OBJuvPOV_Texture}
#declare ConvObject =
union
{
// When the include file below is called, the textures listed above are
applied to the mesh.
// I did it this way because I have limited memory (RAM) and patience so I
hate wading
// through large .inc files looking for textures to replace.
    #include "Box.inc"
}
object {ConvObject}

Hope this helps,


--
Cheers,
Cliff Bowman

http://www.geocities.com/who3d/


Post a reply to this message

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