POV-Ray : Newsgroups : povray.general : Serializing a dictionary : Re: Serializing a dictionary Server Time
12 Jul 2025 17:38:20 EDT (-0400)
  Re: Serializing a dictionary  
From: jr
Date: 10 Jul 2025 14:35:00
Message: <web.687006aae086e5d13ecaab5e6cde94f1@news.povray.org>
hi,

kurtz le pirate <kur### [at] freefr> wrote:
> On 09/07/2025 09:25, jr wrote:
> > ...
> > way more ambitious though, line numbers ! :-). ...
> ...
> more ambitious : yes, lines numbers, list of vars and where vars are
> used. but it's a wip...

agree, a list of the variables and so on is very useful to have, in particular
when "playing" with unfamiliar (someone else's :-)) code.

I don't know MacOS, do you have/use the 'less' and 'vim' programs ?  both can
use  "tags" files created by 'ctags'.  that program, patched[*], can give you
variables, and usage; for instance below the first few lines output based on one
of your scenes (Oct 31st 2023):

$ ectags --sdl-kinds=v -ux pursuitcurve.pov
displayAxis      variable     33 pursuitcurve.pov #declare displayAxis = false;
displayPlane     variable     34 pursuitcurve.pov #declare displayPlane = false;
AxisLen          variable     37 pursuitcurve.pov #declare AxisLen = 16;
Scale            variable     39 pursuitcurve.pov #declare Scale =
AxisLen/image_width;
C                variable    115 pursuitcurve.pov #local C =
_Brightness*_Saturation;
X                variable    116 pursuitcurve.pov #local X = C - (1 -
abs(mod(_Hue/60,2) - 1));
m                variable    117 pursuitcurve.pov #local m = _Brightness-C;
....

only requesting variables, the '-ux' selects an unsorted cross-reference format
to console/terminal; when invoked without options, it'll write a "tags" file.

[*] <drive.google.com/file/d/10ikrIHkMopedFPlq6V4YhnnNn3sY59hC/view?usp=sharing>


regards, jr.


Post a reply to this message

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