add javascript version of o3dgc