[x3d-public] Please place XML header (processing instruction at top of output)
John Carlson
yottzumm at gmail.com
Tue Jun 20 05:24:35 PDT 2023
I'm having issues with x3d.py producing validate XML output on standard
output. Can you guys help? I can work around the problem with file output,
but this is really a pain when working in bash. Putting the XML header
with version first would be great!
For now, I'll investigate file output from Python. I miss the file output
methods from X3DJSAIL!
$ head HelloWorld.py HeloWorld.x3d
==> HelloWorld.py <==
print('<!--')
import x3d
print('-->')
X3D0 = x3d.X3D()
X3D0.profile = "Immersive"
X3D0.version = "3.3"
head1 = x3d.head()
#Alternate encodings: VRML97, X3D ClassicVRML Encoding, X3D Compressed
Binary Encoding (CBE), X3DOM, JSON
meta2 = x3d.meta()
meta2.name = "title"
==> HeloWorld.x3d <==
<!--
x3d.py package 4.0.64.4 loaded, have fun with X3D Graphics!
-->
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.3//EN" "
https://www.web3d.org/specifications/x3d-3.3.dtd">
<X3D profile='Immersive' version='3.3' xmlns:xsd='
http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation='
https://www.web3d.org/specifications/x3d-3.3.xsd'>
<head>
<meta content='HelloWorld.x3d' name='title'/>
<meta content='Simple X3D model example: Hello World!'
name='description'/>
<meta content='30 October 2000' name='created'/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20230620/3d4b5333/attachment.html>
More information about the x3d-public
mailing list