POV-Ray : Newsgroups : povray.newusers : declaring a new texture with a macro Server Time
24 Apr 2024 23:51:21 EDT (-0400)
  declaring a new texture with a macro (Message 11 to 18 of 18)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: Warren
Subject: Re: declaring a new texture with a macro
Date: 1 Dec 2015 04:05:00
Message: <web.565d623a4f56292ca73f5e290@news.povray.org>
Hi,

I've modified my project files to keep the essential and it still doesn't work.
I've uploaded the files (pov, inc and png of heightfield) to a server in a zip
archive. The files are quite small.
Here is the path to download the zip file:
www.ant01.fr/fichiersAnt01/povray/pov_help_macro.zip


Post a reply to this message

From: scott
Subject: Re: declaring a new texture with a macro
Date: 1 Dec 2015 04:44:16
Message: <565d6bf0@news.povray.org>
> (* Note that you're welcome to simplify your scene and trim it down to
> the portion that gives you problems; that, too, helps us help you.

Often just performing this task will identify the problem.


Post a reply to this message

From: scott
Subject: Re: declaring a new texture with a macro
Date: 1 Dec 2015 04:47:39
Message: <565d6cbb@news.povray.org>
> I've modified my project files to keep the essential and it still doesn't work.

Seems to work here - I get a pink coloured background with a beige wave 
going across this middle. Is this what you expected?


Post a reply to this message

From: Warren
Subject: Re: declaring a new texture with a macro
Date: 1 Dec 2015 10:40:00
Message: <web.565dbe1c4f56292ca73f5e290@news.povray.org>
I post the content of the files
File #1 : CouleursPersoAnt.inc


#declare C_marronA1=rgb<113/256, 65/256, 52/256>;
#declare C_marronA2=rgb<117/256, 69/256, 56/256>;

niveau 1 des sols marrons




#declare C_marronB1=rgb<138/256, 89/256, 73/256>;
#declare C_marronB2=rgb<130/256, 85/256, 69/256>;
#declare C_marronB3=rgb<125/256, 77/256, 65/256>;
#declare C_marronB4=C_marronA1;
#declare C_marronB5=C_marronA3;

#declare C_marronC1=C_marronB1*1.15;
#declare C_marronC2=C_marronB2*1.15;
#declare C_marronC3=C_marronB3*1.15;
#declare C_marronC4=C_marronB4*1.15;
#declare C_marronC5=C_marronB5*1.15;
//End of file

File #2 : textures_JeuM_v3.inc

//Nouveau fichier pour les textures
#include "colors.inc"
#include "CouleursPersoAnt.inc"

//Textures des differents sols pour Mercenaires

#macro
T_var_Wrinkles(multiplicateur,Cmarron1,Cmarron2,Cmarron3,Cmarron4,Cmarron5,ValAmbient,ValDiffuse)
    texture{pigment{wrinkles color_map{
                                       [0.0 Cmarron3*multiplicateur]
                                       [0.125 Cmarron2*multiplicateur]
                                       [0.25 Cmarron1*multiplicateur]
                                       [0.375 Cmarron2*multiplicateur]
                                       [0.5 Cmarron3*multiplicateur]
                                       [0.675 Cmarron4*multiplicateur]
                                       [0.75 Cmarron5*multiplicateur]
                                       [0.875 Cmarron4*multiplicateur]
                                       [1.0 Cmarron3*multiplicateur]
                                      }
                    scale 0.005
                    }
            finish { ambient ValAmbient diffuse ValDiffuse}
           }
#end
//Definitions des sols marron avec les macros
#declare
T_marron_MacroNiv1=T_var_Wrinkles(<1,1,1>,C_marronA1,C_marronA2,C_marronA3,C_marronA4,C_marronA5,1,0)
#declare
T_marron_MacroNiv2=T_var_Wrinkles(<1.12,1.1,1.1>,C_marronA1,C_marronA2,C_marronA3,C_marronA4,C_marronA5,1,0)
#declare
T_marron_MacroNiv3=T_var_Wrinkles(<1.32,1.3,1.3>,C_marronA1,C_marronA2,C_marronA3,C_marronA4,C_marronA5,1,0)
#declare
T_marron_MacroNiv4=T_var_Wrinkles(<1.52,1.5,1.5>,C_marronA1,C_marronA2,C_marronA3,C_marronA4,C_marronA5,1,0)

//Texture de la roche des pentes avec sols marrons
#declare T_rocheGriseA=T_var_Wrinkles(<1.3, 1.15,
1>,Gray80,Gray70,Gray60,Gray50,Gray40, 1,0)
#declare T_rocheGriseA2=texture{T_rocheGriseA finish{specular 0.2 diffuse 0.4
ambient 0.24} normal{granite 0.6 scale 0.1}}

File #3 : pentes_v3_x128.pov

#version 3.7;

global_settings{assumed_gamma 1.0}

#declare Anim_Serie=true;
#declare xN=128;
#declare HeightField=true;
#declare Mesh=false;
#declare Photo=true;
#include "textures_JeuM_v3.inc"

#declare T_transition1_2 = texture{gradient y texture_map{[0.0
T_marron_MacroNiv1][0.1 T_rocheGriseA2][0.9 T_rocheGriseA2][1.0
T_marron_MacroNiv2]}};
#declare T_transition2_3 = texture{gradient y texture_map{[0.0
T_marron_MacroNiv2][0.1 T_rocheGriseA2][0.9 T_rocheGriseA2][1.0
T_marron_MacroNiv3]}};
#declare T_transition3_4 = texture{gradient y texture_map{[0.0
T_marron_MacroNiv3][0.1 T_rocheGriseA2][0.9 T_rocheGriseA2][1.0
T_marron_MacroNiv4]}};

#declare tps=clock;

#if (Photo =true)
camera{
       orthographic
       location <0.000001,20,0>
       look_at <0,0,0>
       direction -y
       sky z

  up 2*z
  right 2*x
      }
#else
camera{location <2.5,4,2.5> look_at <0,1,0>}
#end

light_source{<10,20,10>*100 color rgb 1}


height_field{jpg

             #if (Anim_Serie=true)

                     #if (tps>=0 & tps<4)
                        "HF_x128_lineaire1"
                     #end
                     #if (tps>=4 & tps<8)
                        "HF_x128_lineaire2"
                     #end
                     #if (tps>=8 & tps<12)
                        "HF_x128_coin1"//Orniere
                     #end
                     #if (tps>=12 & tps<16)

                     #end
                #end
             #end
             smooth
             translate <-0.5,0,-0.5>


             rotate 90*tps*y
             #end

             scale <2,1,2>
             texture{T_transition1_2}
             scale <1,4,1>

             no_shadow
           }

And the ini file for an auto renderer

-w128
-h128
+a0.3
+KFI0
+KFF15
+KI0
+KF15
+Ipentes_v3_x128.pov
+Ooutput/rr12_x128_.png
+Q9


Post a reply to this message

From: Warren
Subject: Re: declaring a new texture with a macro
Date: 1 Dec 2015 12:00:01
Message: <web.565dd1914f56292ca73f5e290@news.povray.org>
scott <sco### [at] scottcom> wrote:
> > I've modified my project files to keep the essential and it still doesn't work.
>
> Seems to work here - I get a pink coloured background with a beige wave
> going across this middle. Is this what you expected?

I got what I expected in windows 10 with the files mentioned above and the
images you told about but once in Linux Ubuntu (with my laptop, with the desktop
pc I get the expected pictures )I get a pack of 16 totally black pictures.
Lately I tried to tweak the admin rights in folders, removing non ASCII
characters, but it still doesn't work.

I will copy the file of Ubuntu desktop to the Ubuntu laptop. But don't worry
about that , it works on my desktop computer, it's just that I' d like to solve
the problem :(.


Post a reply to this message

From: clipka
Subject: Re: declaring a new texture with a macro
Date: 1 Dec 2015 13:16:07
Message: <565de3e7$1@news.povray.org>
Am 01.12.2015 um 17:57 schrieb Warren:
> scott <sco### [at] scottcom> wrote:
>>> I've modified my project files to keep the essential and it still doesn't work.
>>
>> Seems to work here - I get a pink coloured background with a beige wave
>> going across this middle. Is this what you expected?
> 
> I got what I expected in windows 10 with the files mentioned above and the
> images you told about but once in Linux Ubuntu (with my laptop, with the desktop
> pc I get the expected pictures )I get a pack of 16 totally black pictures.
> Lately I tried to tweak the admin rights in folders, removing non ASCII
> characters, but it still doesn't work.
> 
> I will copy the file of Ubuntu desktop to the Ubuntu laptop. But don't worry
> about that , it works on my desktop computer, it's just that I' d like to solve
> the problem :(.

It's quite apparent to me at this point that /something/ is fishy about
the POV-Ray binary you're using on your laptop.

This immediately raises the following questions:

- Do any of the sample scenes render properly on your laptop?

- What does "povray --version" output on the two Ubuntu computers?

- What versions of Ubuntu are you using on the two machines?

My current best bet is that you're using a different version of POV-Ray
on the laptop machine, and that there's some bug in that version. If
that is the case, I'd really like to get down to the bottom of it.


Post a reply to this message

From: Warren
Subject: Re: declaring a new texture with a macro
Date: 1 Dec 2015 14:05:01
Message: <web.565dee2e4f56292ca73f5e290@news.povray.org>
clipka <ano### [at] anonymousorg> wrote:
>
> It's quite apparent to me at this point that /something/ is fishy about
> the POV-Ray binary you're using on your laptop.
>
> This immediately raises the following questions:
>
> - Do any of the sample scenes render properly on your laptop?
>
> - What does "povray --version" output on the two Ubuntu computers?
>
> - What versions of Ubuntu are you using on the two machines?
>
> My current best bet is that you're using a different version of POV-Ray
> on the laptop machine, and that there's some bug in that version. If
> that is the case, I'd really like to get down to the bottom of it.

Hi,
On the desktop PC in the terminal after a "povray --version" I get :
antoine@PCMapex:~$ povray --version
POV-Ray 3.7.0.unofficial

This is an unofficial version compiled by:
 Antoine FAURE (that's me :) )
 The POV-Ray Team is not responsible for supporting this version.

Copyright 1991-2013 Persistence of Vision Raytracer Pty. Ltd.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Built-in features:
  I/O restrictions:          enabled
  X Window display:          enabled (using SDL)
  Supported image formats:   gif tga iff ppm pgm hdr png jpeg tiff
  Unsupported image formats: openexr

Compilation settings:
  Build architecture:  x86_64-unknown-linux-gnu
  Built/Optimized for: x86_64-unknown-linux-gnu (using -march=native)
  Compiler vendor:     gnu
  Compiler version:    g++ 4.8
  Compiler flags:      -pipe -Wno-multichar -Wno-write-strings
-fno-enforce-eh-specs -s -O3 -ffast-math -march=native -pthread

whereas on the laptop it gives :
antoine@antoine-Presario-V6000:~$ povray --version
POV-Ray 3.7.0.unofficial

This is an unofficial version compiled by:
 Felix Geyer <deb### [at] ubuntucom> for Debian <www.debian.org>
 The POV-Ray Team is not responsible for supporting this version.

Copyright 1991-2013 Persistence of Vision Raytracer Pty. Ltd.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Built-in features:
  I/O restrictions:          enabled
  X Window display:          enabled (using SDL)
  Supported image formats:   gif tga iff ppm pgm hdr png jpeg tiff openexr
  Unsupported image formats: -

Compilation settings:
  Build architecture:  x86_64-pc-linux-gnu
  Built/Optimized for: x86_64-pc-linux-gnu
  Compiler vendor:     gnu
  Compiler version:    g++ 4.8
  Compiler flags:      -pipe -Wno-multichar -Wno-write-strings
-fno-enforce-eh-specs -g -O2 -fstack-protector --param=ssp-buffer-size=4
-Wformat -Werror=format-security -O3 -pthread
antoine@antoine-Presario-V6000:~$

And yes, on the laptop I installed povray via the depots "trusty backports"
whereas on the desktop PC I compiled the sources I download on www.povray.org.


Post a reply to this message

From: Warren
Subject: Re: declaring a new texture with a macro
Date: 2 Dec 2015 10:55:00
Message: <web.565f13ff4f56292ca73f5e290@news.povray.org>
Hi , everybody
I have good news. :)

I removed povray I get from the depots "trusty backports" and installed povray
with the source code from www.povray.org > github and the code I posted in the
post above works fine now. I tested the render example after compiling the new
povray and that was good too.

I want to thank all those who were willing to help me. :)

Antoine.


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

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