Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

QuickSurf.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  *cr                                                                       
00003  *cr            (C) Copyright 1995-2019 The Board of Trustees of the           
00004  *cr                        University of Illinois                       
00005  *cr                         All Rights Reserved                        
00006  *cr                                                                   
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  * RCS INFORMATION:
00011  *
00012  *      $RCSfile: QuickSurf.h,v $
00013  *      $Author: johns $        $Locker:  $             $State: Exp $
00014  *      $Revision: 1.21 $       $Date: 2019/01/17 21:21:01 $
00015  *
00016  ***************************************************************************
00017  * DESCRIPTION:
00018  *   Fast gaussian surface representation
00019  ***************************************************************************/
00020 #ifndef QUICKSURF_H
00021 #define QUICKSURF_H
00022 
00023 #include "AtomSel.h"
00024 #include "ResizeArray.h"
00025 #include "Isosurface.h"
00026 #include "WKFUtils.h"
00027 #include "VolumetricData.h"
00028 #include "VMDDisplayList.h"
00029 
00030 class CUDAQuickSurf;
00031 
00032 class QuickSurf {
00033 private:
00034   float *volmap;           
00035   float *voltexmap;        
00036   IsoSurface s;            
00037   float isovalue;          
00038   float solidcolor[3];     
00039   int numvoxels[3];        
00040   float origin[3];         
00041   float xaxis[3];          
00042   float yaxis[3];          
00043   float zaxis[3];          
00044 
00045   int force_cpuonly;       
00046   CUDAQuickSurf *cudaqs;   
00047 
00048   wkf_timerhandle timer;   
00049   double pretime;          
00050   double voltime;          
00051   double gradtime;         
00052   double mctime;           
00053   double mcverttime;       
00054   double reptime;          
00055 
00056 public:
00057   QuickSurf(int forcecpuonly=0);
00058   ~QuickSurf(void);
00059 
00060   void free_gpu_memory(void); 
00061 
00062 
00063 
00064   int calc_surf(AtomSel * atomSel, DrawMolecule *mymol, 
00065                 const float *atompos, const float *atomradii,
00066                 int quality, float radscale, float gridspacing, float isovalue,
00067                 const int *colidx, const float *cmap, VMDDisplayList *cmdList); 
00068 
00069   VolumetricData * calc_density_map(AtomSel * atomSel, DrawMolecule *mymol, 
00070                                     const float *atompos, 
00071                                     const float *atomradii,
00072                                     int quality, float radscale, 
00073                                     float gridspacing);
00074 
00075 private:
00076   int get_trimesh(int &numverts, float *&v3fv, float *&n3fv, float *&c3fv,
00077                   int &numfacets, int *&fiv);
00078 
00079   int draw_trimesh(VMDDisplayList *cmdList);
00080 
00081 };
00082 
00083 #endif
00084 

Generated on Fri Apr 19 02:45:18 2024 for VMD (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002