[x3d-public] X3D to .py conversion refinement, continued: wild duck chase

Brutzman, Donald (Don) (CIV) brutzman at nps.edu
Thu May 9 09:31:44 PDT 2019


Hi John, thanks for checking in your useful improvements .x3d -> python conversion into our pyjnius subversion directory.

	Diff log: Moved sets to same line as constructor
	https://sourceforge.net/p/x3d/code/28428/

The latest version (fewer line breaks) runs without problems and looks good for me too.  Example of current output (both python and java) attached.

Suggestion #1: for readability, don't skip lines when only a single close-parenthesis appears, simply append to end of line.  See .java as an example:

     .setAppearance(new AppearanceObject()
       .setMaterial(new MaterialObject().setUSE("MaterialLightBlue")))))));

Suggestion: also please check in your removal of all of the X3D type casting (SFString) (SFFloat) (SFInt32) etc. for further testing.  Let's chase Duck Typing.

	https://en.wikipedia.org/wiki/Duck_typing

You reported encountered a few problems with the SFString casting... OK, am thinking it would be best to grasp those nettles, look at all of the exceptions closely, and (hopefully) fix each.  We've already made great progress on that score.  Often the full fix is pretty simple, i.e. adding another utility method to X3DJSAIL that might have been previously overlooked.

It typically takes a while (all night) to run the full set of .x3d -> .py conversions on all X3D Examples Archives, and so will wait for when you are ready (tonight, tomorrow night, whenever).  That next build will give us another round of diffs to review and issues to diagnose/fix.

In the meantime, I will also try to reduce the repetitive/excessive number of "regex failed due to insufficient memory" provoked during pyjnius invocation of X3DJSAIL. If those can be silenced (for now) then I think the build log will again be manageable.

Hope this finds you well.  Thanks as ever for the excellent steady progress!  8)

all the best, Don
-- 
Don Brutzman  Naval Postgraduate School, Code USW/Br       brutzman at nps.edu
Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA   +1.831.656.2149
X3D graphics, virtual worlds, navy robotics http://faculty.nps.edu/brutzman
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: HelloWorld.py
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20190509/846d7fc0/attachment-0002.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: HelloWorld.java
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20190509/846d7fc0/attachment-0003.ksh>


More information about the x3d-public mailing list