POV-Ray : Newsgroups : povray.advanced-users : POVRay and XML : Re: POVRay and XML Server Time
28 Jul 2024 20:32:37 EDT (-0400)
  Re: POVRay and XML  
From: Bernd Fuhrmann
Date: 1 Jan 2005 05:50:19
Message: <41d6806b$1@news.povray.org>
Warp wrote:
> Bernd Fuhrmann <Sil### [at] gmxde> wrote:
> 
>>Why not? It isn't that difficult. People write XHTML, MathML and even 
>>SVG by hand. At least I do. So why not POVRay?
> 
>   Because there already is a language which is ten times easier to
> write and understand.

But not to transform. Automatic code generation is an important goal. At 
least I want to achieve it.

>>It would be possible to write material libraries, object libraries and 
>>so on without clobbering the global namespace.
> 
> 
>   If this is the problem, why is XML the solution?

Because XML supports namespaces via xmlns.

>   The POV-Ray SDL is a *programming language*, XML is a markup language.
> Trying to create a programming language with a markup language is not
> the best possible idea.

Well. POVRay syntax won't stay the same forever, will it? Extensions 
will surely be added. There needs to be a system that assures that these 
extensions wont result in any conflicts with old scenes. How can you 
know that the names you use for variables won't ever be used by POVRay 
itself? Your scenes might not render in POVRay 5.

>>It would become possible to access the camera settings to adjust certain 
>>values. This would make the implementation of HUD systems possible 
>>(useful if you want to mark or label certain things in your scene).
> 
> 
>   And XML is the best solution for this because...?

It isn't. XML is a general markup language made by humans and has 
certainly it's flaws. But XML is the best general markup language I know 
of. In fact you might ask any IT professional for the best general 
markup language and most sane will tell you: "Use XML". There is XSLT, a 
general transformation language. It is (with a few tweaks) as powerful 
as the lambda calculus and thus as powerful as POVRay itself.

>>One could even convert whole models to meshes and apply mesh 
>>modificators on them. This is AFAIK not yet possible in POVRay.
> 
>   And how on earth does XML make this any easier? Does XML have some
> magic which will allow you to tesselate any given surface?

Not really. You'd have to code it all yourself. But this is still 
possible. I guess it will take 1/2 year. But the point is: You cannot do 
this at all with POVRay since you cannot access scene objects. XSLT 
could do this. Or what if you wanted an object to appear always in the 
same size. You would have to access the camera data. This cannot be 
written as an POVRay include file. You can write it easily as XSLT 
transformation from one scene to another.

>>Ok, maybe some of these things can be done in POVRay file format. But if 
>>they can be done, how clean can they be done?
> 
> 
>   It is aknowledged that the current SDL has reached its practical limits
> and that a better language may be necessary, but XML is certainly not
> the answer. POV-Ray needs a programming language, not a markup language.

Tell me: What is the fundamental difference between a programming 
language and a markup language. Both are finite. Both have a tree-like 
structure.

Regards,
Bernd Fuhrmann


Post a reply to this message

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