POV-Ray : Newsgroups : povray.newusers : Problem with certain text {fonts} : Re: Problem with certain text {fonts} Server Time
29 Jul 2024 06:26:47 EDT (-0400)
  Re: Problem with certain text {fonts}  
From: Patrick Hagerty
Date: 6 Jul 2006 18:14:03
Message: <44ad8b2b$1@news.povray.org>
Sorry for not replying for a while.  Holiday and vacation activities keeping 
me otherwise occupied.

Well, I've seen this problem with several fonts.  But one that's available 
free from multiple web sites is "01-01-00.ttr".  I did a Google search and 
it showed up all over the place.

So, I'll post below the code that shows the problem.
start code...
//----------------------------------------------------------------------------------------------------------------
#version 3.6;

global_settings
{
    assumed_gamma 1.0
    //charset ascii       // standard ascii (only 0 to 127 are valid)
    charset utf8      // unicode
    //charset sys       // system specific charset
}

// ----------------------------------------

camera
{
    location  <0.0, 1.0, -6.0>
    direction 1.5*z
    right     4/3*x
    look_at   <0.0, 0.0,  6.0>
}

sky_sphere {pigment{ gradient y color_map { [0.0 color blue 0.6] [1.0 color 
rgb 1] }}}

light_source
{
  <0, 0, 0>            // light's position (translated below)
  color rgb <1, 1, 1>  // light's color
  translate <-30, 30, -30>
}

// ----------------------------------------

#declare Text_Tex = texture
{
    pigment{ color rgb <0.98, 0.83, 0.58> }
    normal{ dents 1.2 scale 0.01 }
    finish{ phong 0 brilliance 0.7 }
}

#declare TextDepth = 0.22;
#declare CharSeparation = <0.06, 0, 0>;

#declare FontName = "01-01-00.TTF";
#declare xPos = -3.4;
#declare yPos = 0.4;
#declare zPos = 4.2;

#declare testString1 = "`1234567890-=";
#declare testString2 = "~!@#$%^&*()_+";
#declare testString3 = "qwertyuiop[]\\";
#declare testString4 = "QWERTYUIOP{}|";
#declare testString5 = "asdfghjkl;'";
#declare testString6 = "ASDFGHJKL:\"";
#declare testString7 = "zxcvbnm,./";
#declare testString8 = "ZXCVBNM<>?";

text
{
    ttf             // font type (only TrueType format for now)
    FontName,  // Microsoft Windows-format TrueType font file name
    testString5,    // Change string number (1-8) to try different 
characters.
    TextDepth,              // the extrusion depth
    CharSeparation               // inter-character spacing

    texture { Text_Tex }
    rotate <0, -2, 0>
    translate <xPos, yPos, zPos>
}

plane { y, 0 pigment { color rgb <0.7,0.5,0.3> } }

//----------------------------------------------------------------------------------------------------------------
... end code

- Patrick

"StephenS" <stephen@nospam> wrote in message 
news:44a85a61$1@news.povray.org...
> ...
>> Finally, what would be the appropriate group for this code posting?
> ...
> If you can point us to the correct place for the font, and the code is 
> short(under 20 lines), this group is fine.
>
> If you want to attach files(font, code, picture) a binaries group would be 
> best, perhaps povray.binaries.scene-files.
>
> Stephen
>


Post a reply to this message

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