Skip to content

Commit

Permalink
Last commit before Git migration.
Browse files Browse the repository at this point in the history
  • Loading branch information
BradLarson committed Jul 23, 2014
1 parent e72db48 commit 9562949
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 6 deletions.
2 changes: 2 additions & 0 deletions SLSMolecule+PDB.m
Original file line number Diff line number Diff line change
Expand Up @@ -769,6 +769,8 @@ - (BOOL)readFromPDBFileToDatabase:(NSError **)error;
}
else if ([lineIdentifier isEqualToString:@"SEQRES"])
{
//#warning: Fix the sequence information here, which isn't processing right

if (sequence == nil)
{
sequence = [[currentLine substringFromIndex:14] stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]];
Expand Down
2 changes: 2 additions & 0 deletions SLSMoleculeAppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,13 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
newSplitViewController.delegate = (SLSMoleculeiPadRootViewController *)rootViewController;
splitViewController = newSplitViewController;
[window addSubview:splitViewController.view];
self.window.rootViewController = splitViewController;
}
else
{
rootViewController = [[SLSMoleculeRootViewController alloc] init];
[window addSubview:rootViewController.view];
self.window.rootViewController = rootViewController;
}


Expand Down
6 changes: 3 additions & 3 deletions SLSOpenGLES11Renderer.m
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ - (void)renderFrameForMolecule:(SLSMolecule *)molecule;
}

dispatch_async(openGLESContextQueue, ^{
// CFAbsoluteTime elapsedTime, startTime = CFAbsoluteTimeGetCurrent();
// CFAbsoluteTime elapsedTime, startTime = CFAbsoluteTimeGetCurrent();

isFrameRenderingFinished = NO;

Expand Down Expand Up @@ -291,8 +291,8 @@ - (void)renderFrameForMolecule:(SLSMolecule *)molecule;
[self presentRenderBuffer];
isFrameRenderingFinished = YES;

// elapsedTime = CFAbsoluteTimeGetCurrent() - startTime;
// NSLog(@"Render time: %.1f ms, Triangles per second: %.0f", elapsedTime * 1000.0, (CGFloat)totalNumberOfTriangles / elapsedTime);
// elapsedTime = CFAbsoluteTimeGetCurrent() - startTime;
// NSLog(@"Render time: %.1f ms, Triangles per second: %.0f", elapsedTime * 1000.0, (CGFloat)totalNumberOfTriangles / elapsedTime);

dispatch_semaphore_signal(frameRenderingSemaphore);
});
Expand Down
2 changes: 1 addition & 1 deletion SLSOpenGLESRenderer.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ extern NSString *const kSLSMoleculeShadowCalculationEndedNotification;
// OpenGL helper functions
void normalize(GLfloat *v);

typedef typedef struct {
typedef struct {
GLubyte redComponent;
GLubyte greenComponent;
GLubyte blueComponent;
Expand Down
4 changes: 2 additions & 2 deletions SLSOpenGLESRenderer.m
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ - (void)bindVertexBuffersForMolecule;
{
glGenBuffers(1, &atomIndexBufferHandle[currentAtomIndexBufferIndex]);
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, atomIndexBufferHandle[currentAtomIndexBufferIndex]);
glBufferData(GL_ELEMENT_ARRAY_BUFFER, [atomIndexBuffers[currentAtomIndexBufferIndex] length], (GLushort *)[atomIndexBuffers[currentAtomIndexBufferIndex] bytes], GL_STATIC_DRAW);
glBufferData(GL_ELEMENT_ARRAY_BUFFER, [atomIndexBuffers[currentAtomIndexBufferIndex] length], (GLushort *)[atomIndexBuffers[currentAtomIndexBufferIndex] bytes], GL_STATIC_DRAW);

numberOfIndicesInBuffer[currentAtomIndexBufferIndex] = ([atomIndexBuffers[currentAtomIndexBufferIndex] length] / sizeof(GLushort));

Expand All @@ -407,7 +407,7 @@ - (void)bindVertexBuffersForMolecule;
{
glGenBuffers(1, &atomVertexBufferHandles[currentAtomVBOIndex]);
glBindBuffer(GL_ARRAY_BUFFER, atomVertexBufferHandles[currentAtomVBOIndex]);
glBufferData(GL_ARRAY_BUFFER, [atomVBOs[currentAtomVBOIndex] length], (void *)[atomVBOs[currentAtomVBOIndex] bytes], GL_STATIC_DRAW);
glBufferData(GL_ARRAY_BUFFER, [atomVBOs[currentAtomVBOIndex] length], (void *)[atomVBOs[currentAtomVBOIndex] bytes], GL_STATIC_DRAW);

atomVBOs[currentAtomVBOIndex] = nil;
}
Expand Down

0 comments on commit 9562949

Please sign in to comment.