schrodinger / pymol-open-source

Open-source foundation of the user-sponsored PyMOL molecular visualization system.
https://pymol.org/
Other
1.2k stars 281 forks source link

VRML export of distance measurements broken #209

Closed giagitom closed 2 years ago

giagitom commented 2 years ago

The exporter returns always radius 0.000000 for sphere and cylinder primitives, resulting in empty objects when loaded into blender

Here an example

Transform {
 translation -29.105999 24.090500 -0.028000
 rotation 0.982072 0.000000 0.188507 2.089593
 children [
  Shape {
   geometry Cylinder {
    radius 0.000000
    height 4.019477
    bottom FALSE
    top    FALSE
   }
   appearance Appearance {
   material Material { diffuseColor 1.0000 1.0000 0.0000 
                       specularColor 0.8 0.8 0.8 
                       shininess 0.8 }
   }
  }
  Transform {
   translation 0.0 2.009739 0.0
   children Shape {
    geometry Sphere { radius 0.000000 }
    appearance Appearance {
   material Material { diffuseColor 1.0000 1.0000 0.0000 
                       specularColor 0.8 0.8 0.8 
                       shininess 0.8 }
    }
   }
  }
  Transform {
   translation 0.0 -2.009739 0.0
   children Shape {
    geometry Sphere { radius 0.000000 }
    appearance Appearance {
   material Material { diffuseColor 1.0000 1.0000 0.0000 
                       specularColor 0.8 0.8 0.8 
                       shininess 0.8 }
    }
   }
  }
 ]
}
JarrettSJohnson commented 2 years ago

Ah, I misread the title. I assumed all spheres and cylinders were broken.

JarrettSJohnson commented 2 years ago

I still might need more information. When trying to export alanine with a distance measurement, they appear fine for me and all radii in the file are non-zero.

image

giagitom commented 2 years ago

Ok I found the cause. I was using a pse were dash_radius was set to 0 for some reason. With radius to 0 Dashed lines are still visible in real time but when exported to VRML they have 0 radius.

JarrettSJohnson commented 2 years ago

By chance does your measurements show up when ray traced?

giagitom commented 2 years ago

Yes they appear when ray traced.

JarrettSJohnson commented 2 years ago

dash_radius is zero by default, so there's something else at play here. Can you email me a session file or reproduceable steps that shows this behavior?

giagitom commented 2 years ago

I'm unable to reproduce the issue in the same pse file.. Maybe something I have done in the middle but not saved it sadly..

If i find a way to reproduce it I will let you know

JarrettSJohnson commented 2 years ago

Thanks. I'll close this in the meantime. Feel free to reopen if something weird happens again.