From: Josh Vermaas (vermaas2_at_illinois.edu)
Date: Tue Dec 30 2014 - 20:07:48 CST

Hi Rebecca,

I'm most familiar with Linux systems, so that's what I use when I build
it for my own purposes. However I think going into the code is overkill
for the problem you are trying to address. If you just want to check for
discontinuities, I'd imagine a script would suffice that checks for the
adjacency of sequential CA atoms. Those with big distances between two
sequential CA atoms would point to a problematic case that needs to be
looked at more closely.

My big question is what you want the triangular meshes for. Is it for
some kind of 3-D printing thing? I can't imagine a ribbon being the best
representation of the protein, and most of the other representations
don't have this discontinuity problem.

-Josh

On 12/29/2014 11:51 AM, Rebecca Taylor wrote:
> Dear Josh (and everyone),
>
> I downloaded the source and looked through it. It appears that both
> the draw_protein_ribbons_new and draw_proteins_ribbons_old functions
> within the file "DrawMolItemRibbons.C" at lines 481 and 1352,
> respectively, both call the "draw_spline_new" function.
>
> I would like to print to the console the inputs to that function, each
> time it is called. (this information would let me identify where
> discontinuities are). So this could be done in one place by modifying
> the draw_spline_new function to trace its inputs.
>
> My next question is about compiling VMD. Is this most easily done on
> Linux or Mac or Windows. The documentation the describes compilation
> makes it sound like an involved process. I work on a mac usually, but
> have access to Linux or Windows systems. What platform do you
> developers use to recompile VMD?
>
> best,
> -bex
>
> On Mon, Dec 29, 2014 at 9:08 AM, Rebecca Taylor <rebeccat_at_stanford.edu
> <mailto:rebeccat_at_stanford.edu>> wrote:
>
> Dear Josh,
>
> Thank you for your detailed response. I am concerning myself with
> just protein models right now (not prot-dna or dna), and right now
> I'm only concerned with rendering the backbone.
>
> A good example is PDB file 12AS
> (http://www.rcsb.org/pdb/download/downloadFile.do?fileFormat=pdb&compression=NO&structureId=12AS)
> from the RSCB database. If I run the TCL script (pasted below), it
> throws an error about the unusual structure, but as far as I can
> tell, the entire backbone has been rendered. With other molecules
> like 2MYS the uncrystalized flexible chains are not included in
> the PDB and thus the non-sequential resids lead to rendering errors.
>
> I want to know where there are gaps in the model and was hoping
> that I would be able to programmatically determine this. Barring
> that, I'd like to be able to run a check for completeness of the
> backbone when that error occurs, so even if VMD can't give me the
> specifics, I can get information about whether or not the backbone
> is a complete, one-piece mesh.
>
> To get this sort of info, I should modify the
> "draw_protein_ribbons_old" function and recompile VMD on my
> machine? Based on your helpful email with the calls that lead to
> my error, it sounds like that is the only way to get a list of
> rendered backbone segments.
>
> I can look into doing this if that's the way to go.
>
> many thanks and happy holidays.
>
> best,
> -bex
>
>
> *** Sample TCL script****
> ### TCL file for generating meshes of ribbon models of proteins.
> menu files off
> menu files on
> display resetview
> mol addrep 0
> display resetview
> mol new {/Users/bex/PDBs/12AS.pdb} type {pdb} first 0 last -1 step
> 1 waitfor 1
> animate style Loop
> menu graphics off
> menu graphics on
> axes location Off
> mol modstyle 0 0 NewRibbons 1.520000 10.000000 2.520000 0
> mol color Name
> mol representation NewRibbons 1.520000 10.000000 2.520000 0
> mol selection chain
> mol material Opaque
> display resetview
> mol modstyle 0 0 NewRibbons 0.300000 10.000000 3.000000 0
> mol modstyle 0 0 NewRibbons 1.520000 10.000000 2.520000 0
> mol color Name
> mol representation NewRibbons 1.520000 10.000000 2.520000 0
> mol modselect 0 0 chain is A
> mol material Opaque
> mol addrep 0
> mol modstyle 1 0 Beads 0.700000 12.000000
> mol modstyle 1 0 Beads 1.100000 12.000000
> mol color Name
> mol representation Beads 1.000000 12.000000
> mol selection name CA and chain is A and resid 10 20 30 40 50 60
> 70 80 90 100 110 120 130 140 150 160 170 180 190 200 210 220 230
> 240 250 260 270 280 290 300 310 320 330
> mol material Opaque
> mol modrep 1 0
> mol addrep 0
> mol modstyle 2 0 Beads 0.700000 12.000000
> mol modstyle 2 0 Beads 0.700000 12.000000
> mol color Name
> mol representation Beads 0.700000 12.000000
> mol selection name CA and chain is A and resid 4 5 6 7 8 9 10 11
> 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
> 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55
> 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77
> 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99
> 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115
> 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131
> 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147
> 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163
> 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179
> 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195
> 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211
> 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227
> 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243
> 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259
> 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275
> 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291
> 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307
> 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323
> 324 325 326 327 328 329 330 331
> mol material Opaque
> mol modrep 2 0
> display resetview
> menu render off
> menu render on
> render STL /Users/bex/12AS_A_Basic.stl
>
> On Fri, Dec 26, 2014 at 5:20 AM, Josh Vermaas
> <vermaas2_at_illinois.edu <mailto:vermaas2_at_illinois.edu>> wrote:
>
> Hi Rebecca,
>
> There isn't a way of getting more detailed information beyond
> looking into the source code.
>
> rc |= draw_protein_ribbons_old(framepos, bres, brad,
> ribbon_width, use_cyl);
> rc |= draw_nucleic_ribbons(framepos, bres, brad,
> ribbon_width, use_cyl, 0, 0);
> rc |= draw_base_sugar_rings(framepos, bres, brad,
> ribbon_width, use_cyl);
>
> // XXX put the more specific error messages back in here if
> we feel
> // that they are helpful to the user.
> if (rc != 0) {
> if (emitstructwarning())
> msgErr << "Warning: ribbons code encountered an unusual
> structure, geometry may not look as expected." << sendmsg;
> }
>
> What this means is that one of those three methods failed to
> draw things, and as written, there is no way to determine
> which one. What is in your system (ideally you could share a
> pdb code...)? Is it just protein, or is it some combination of
> protein, DNA, or sugars? I've seen many different reasons why
> these methods fail, so there isn't one specific problem that
> causes this. Generally, non-sequential resids cause problems,
> or if there are any negative resids (particularly in DNA).
>
> -Josh Vermaas
>
>
> On 12/25/14 11:15 PM, Rebecca Taylor wrote:
>> Hello everyone, I'm converting multiple PDB files into ribbon
>> models ('new ribbons') and thereafter generating triangular
>> meshes. I've scoured the previous posts for this topic, but I
>> can't find anything.
>>
>> I get the following error when a ribbon isn't completely
>> rendered:
>> "ERROR) Warning: ribbons code encountered an unusual
>> structure, geometry may not look as expected."
>>
>> I'd love to know the residue ids for the residues NOT
>> rendered. Basically I want to know where the gaps are, but
>> this information isn't an output. Is there some command I can
>> issue to get VMD to output more information about each error?
>>
>> Many thanks and happy holidays,
>> -rebecca
>>
>> --
>> Rebecca Taylor
>> Post Doctoral Fellow
>> Spudich Lab (spudlab.stanford.edu <http://spudlab.stanford.edu>)
>> Biochemistry
>> Stanford University
>> 650-319-5534 <tel:650-319-5534>
>
>
>
>
> --
> Rebecca Taylor
> Post Doctoral Fellow
> Spudich Lab (spudlab.stanford.edu <http://spudlab.stanford.edu>)
> Biochemistry
> Stanford University
> 650-319-5534 <tel:650-319-5534>
>
>
>
>
> --
> Rebecca Taylor
> Post Doctoral Fellow
> Spudich Lab (spudlab.stanford.edu <http://spudlab.stanford.edu>)
> Biochemistry
> Stanford University
> 650-319-5534