moltools / CineMol

Direct-to-SVG small molecule drawer.
https://moltools.bioinformatics.nl/cinemol
MIT License
21 stars 3 forks source link

What are reasonable values for focal length? #9

Open svandenhaute opened 1 month ago

svandenhaute commented 1 month ago

I can't succeed in rendering .svg's with perspective. Any time I try to set the focal length to anything except None, he ends up creating an invalid SVG, or if it is valid, something which looks completely off. I've installed the latest cinemol master. See below for an example SDF molecule

     RDKit          3D

  7  6  0  0  0  0  0  0  0  0999 V2000
    1.1219    1.1718   -0.7086 O   0  0  0  0  0  0  0  0  0  0  0  0
    0.6238    0.1250   -0.5602 C   0  0  0  0  0  0  0  0  0  0  0  0
   -0.4183   -0.1429    0.4164 C   0  0  1  0  0  0  0  0  0  0  0  0
    0.9436   -0.7026   -1.2411 H   0  0  0  0  0  0  0  0  0  0  0  0
   -0.1615   -0.1105    1.4799 H   0  0  0  0  0  0  0  0  0  0  0  0
   -1.1255    0.7045    0.3051 H   0  0  0  0  0  0  0  0  0  0  0  0
   -0.9839   -1.0453    0.3085 H   0  0  0  0  0  0  0  0  0  0  0  0
  1  2  2  0
  2  3  1  0
  2  4  1  0
  3  5  1  1
  3  6  1  0
  3  7  1  0
M  END
davidmeijer commented 1 month ago

Thank you for trying out CineMol! I'm out today but I'll look into your issue tomorrow.

svandenhaute commented 1 month ago

Any updates ? :)

davidmeijer commented 1 month ago

Sorry for the communication silence! I had a look and it seems to be an implementation error. I'll need to release a new major version, but I won't be able to work on it now because I'm on holiday. I'll be back August 12 and roll out a new version.

svandenhaute commented 1 month ago

Thanks, looking forward!

svandenhaute commented 1 week ago

@davidmeijer any updates?