LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: tomfunkhouser[P]gaps/pkgs/R3Utils/./R3SurfelViewer.h
// Function: gaps::R3SurfelViewer::SetImagePointsVisibility(int)
inline void R3SurfelViewer::
SetImagePointsVisibility(int visibility)
{
  // Set image points visibililty
  if (visibility == -1) image_points_visibility = 1 - image_points_visibility;
  else if (visibility == 0) image_points_visibility = 0;
  else image_points_visibility = 1;
}

// Assembly:
movq %rdi, -0x8(%rsp)
movl %esi, -0xc(%rsp)
movq -0x8(%rsp), %rax
movq %rax, -0x18(%rsp)
cmpl $-0x1, -0xc(%rsp)
jne 0x3f9f2
movq -0x18(%rsp), %rax
movl $0x1, %ecx
subl 0x330(%rax), %ecx
movl %ecx, 0x330(%rax)
jmp 0x3fa1b
cmpl $0x0, -0xc(%rsp)
jne 0x3fa0a
movq -0x18(%rsp), %rax
movl $0x0, 0x330(%rax)
jmp 0x3fa19
movq -0x18(%rsp), %rax
movl $0x1, 0x330(%rax)
jmp 0x3fa1b
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Utils/./R3SurfelViewer.h
// Function: gaps::R3SurfelViewer::SetCenterPointVisibility(int)
inline void R3SurfelViewer::
SetCenterPointVisibility(int visibility)
{
  // Set center point visibililty
  if (visibility == -1) center_point_visibility = 1 - center_point_visibility;
  else if (visibility == 0) center_point_visibility = 0;
  else center_point_visibility = 1;
}

// Assembly:
movq %rdi, -0x8(%rsp)
movl %esi, -0xc(%rsp)
movq -0x8(%rsp), %rax
movq %rax, -0x18(%rsp)
cmpl $-0x1, -0xc(%rsp)
jne 0x3fa52
movq -0x18(%rsp), %rax
movl $0x1, %ecx
subl 0x334(%rax), %ecx
movl %ecx, 0x334(%rax)
jmp 0x3fa7b
cmpl $0x0, -0xc(%rsp)
jne 0x3fa6a
movq -0x18(%rsp), %rax
movl $0x0, 0x334(%rax)
jmp 0x3fa79
movq -0x18(%rsp), %rax
movl $0x1, 0x334(%rax)
jmp 0x3fa7b
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Utils/./R3SurfelViewer.h
// Function: gaps::R3SurfelViewer::SetViewingExtentVisibility(int)
inline void R3SurfelViewer::
SetViewingExtentVisibility(int visibility)
{
  // Set viewing extent visibililty
  if (visibility == -1) viewing_extent_visibility = 1 - viewing_extent_visibility;
  else if (visibility == 0) viewing_extent_visibility = 0;
  else viewing_extent_visibility = 1;
}

// Assembly:
movq %rdi, -0x8(%rsp)
movl %esi, -0xc(%rsp)
movq -0x8(%rsp), %rax
movq %rax, -0x18(%rsp)
cmpl $-0x1, -0xc(%rsp)
jne 0x3fab2
movq -0x18(%rsp), %rax
movl $0x1, %ecx
subl 0x338(%rax), %ecx
movl %ecx, 0x338(%rax)
jmp 0x3fadb
cmpl $0x0, -0xc(%rsp)
jne 0x3faca
movq -0x18(%rsp), %rax
movl $0x0, 0x338(%rax)
jmp 0x3fad9
movq -0x18(%rsp), %rax
movl $0x1, 0x338(%rax)
jmp 0x3fadb
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Utils/./R3SurfelViewer.h
// Function: gaps::R3SurfelViewer::SetAxesVisibility(int)
inline void R3SurfelViewer::
SetAxesVisibility(int visibility)
{
  // Set axes visibililty
  if (visibility == -1) axes_visibility = 1 - axes_visibility;
  else if (visibility == 0) axes_visibility = 0;
  else axes_visibility = 1;
}

// Assembly:
movq %rdi, -0x8(%rsp)
movl %esi, -0xc(%rsp)
movq -0x8(%rsp), %rax
movq %rax, -0x18(%rsp)
cmpl $-0x1, -0xc(%rsp)
jne 0x3fb12
movq -0x18(%rsp), %rax
movl $0x1, %ecx
subl 0x33c(%rax), %ecx
movl %ecx, 0x33c(%rax)
jmp 0x3fb3b
cmpl $0x0, -0xc(%rsp)
jne 0x3fb2a
movq -0x18(%rsp), %rax
movl $0x0, 0x33c(%rax)
jmp 0x3fb39
movq -0x18(%rsp), %rax
movl $0x1, 0x33c(%rax)
jmp 0x3fb3b
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Utils/./R3SurfelViewer.h
// Function: gaps::R3SurfelViewer::SetSubsamplingFactor(int)
inline void R3SurfelViewer::
SetSubsamplingFactor(int subsampling_factor)
{
  // Just checking
  if (subsampling_factor < 1) subsampling_factor = 1;
  static const int max_subsampling_factor = 1024*1024;
  if (subsampling_factor > max_subsampling_factor) subsampling_factor = max_subsampling_factor;

  // Set subsampling factor
  this->subsampling_factor = subsampling_factor;

  // Invalidate VBO buffers
  InvalidateVBO();
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movq 0x10(%rsp), %rax
movq %rax, (%rsp)
cmpl $0x1, 0xc(%rsp)
jge 0x3fe65
movl $0x1, 0xc(%rsp)
cmpl $0x100000, 0xc(%rsp)    # imm = 0x100000
jle 0x3fe77
movl $0x100000, 0xc(%rsp)    # imm = 0x100000
movq (%rsp), %rdi
movl 0xc(%rsp), %eax
movl %eax, 0x48c(%rdi)
movq (%rdi), %rax
callq *0x378(%rax)
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/RNBasics/RNQueue.cpp
// Function: gaps::RNVQueue::FindEntry(void const*) const
RNQueueEntry *RNVQueue::
FindEntry(const void *data) const
{
  // Search for entry matching data
  for (int i = 0; i < nentries; i++) {
    RNQueueEntry *entry = KthEntry(i);
    if (EntryContents(entry) == data) return entry;
  }

  // Entry was not found
  return NULL;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
movl $0x0, 0x1c(%rsp)
movq 0x8(%rsp), %rcx
movl 0x1c(%rsp), %eax
cmpl 0x10(%rcx), %eax
jge 0x1a2cd5
movq 0x8(%rsp), %rdi
movl 0x1c(%rsp), %esi
callq 0x41250
movq 0x8(%rsp), %rdi
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rsi
callq 0x41240
movq (%rax), %rax
cmpq 0x20(%rsp), %rax
jne 0x1a2cc6
movq 0x10(%rsp), %rax
movq %rax, 0x30(%rsp)
jmp 0x1a2cde
jmp 0x1a2cc8
movl 0x1c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x1a2c80
movq $0x0, 0x30(%rsp)
movq 0x30(%rsp), %rax
addq $0x38, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/RNBasics/RNQueue.cpp
// Function: gaps::RNVQueue::InternalInsert(void*, int)
RNQueueEntry *RNVQueue::
InternalInsert(void *data, int k)
{
  // Make sure there is enough storage for new entry
  Resize(nentries + 1);

  // Increment number of entries
  nentries++;

  // Check where entry is being inserted
  if (k == 0) {
    // Insert into head by shifting head back one
    head = (head + entries.NEntries() - 1) % entries.NEntries();
  }
  else if (k < (nentries-1)) {
    // Insert into middle by shifting all subsequent entries up one
    Shift(k, 0, 1);
  }

  // Get Kth entry
  RNQueueEntry *entry = KthEntry(k);

  // Insert data in kth entry 
  EntryContents(entry) = data;

  // Return entry
  return entry;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movl %edx, 0x24(%rsp)
movq 0x30(%rsp), %rdi
movq %rdi, 0x10(%rsp)
movl 0x10(%rdi), %esi
addl $0x1, %esi
callq 0x1a2dd0
movq 0x10(%rsp), %rax
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
cmpl $0x0, 0x24(%rsp)
jne 0x1a2d69
movq 0x10(%rsp), %rdi
movl 0x14(%rdi), %eax
movl %eax, 0x8(%rsp)
callq 0x2f1c0
movq 0x10(%rsp), %rdi
movl %eax, %ecx
movl 0x8(%rsp), %eax
addl %ecx, %eax
subl $0x1, %eax
movl %eax, 0xc(%rsp)
callq 0x2f1c0
movl %eax, %ecx
movl 0xc(%rsp), %eax
cltd
idivl %ecx
movq 0x10(%rsp), %rax
movl %edx, 0x14(%rax)
jmp 0x1a2d93
movq 0x10(%rsp), %rcx
movl 0x24(%rsp), %eax
movl 0x10(%rcx), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jge 0x1a2d91
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %esi
xorl %edx, %edx
movl $0x1, %ecx
callq 0x1a2ef0
jmp 0x1a2d93
movq 0x10(%rsp), %rdi
movl 0x24(%rsp), %esi
callq 0x41250
movq 0x10(%rsp), %rdi
movq %rax, 0x18(%rsp)
movq 0x28(%rsp), %rax
movq %rax, (%rsp)
movq 0x18(%rsp), %rsi
callq 0x41240
movq (%rsp), %rcx
movq %rcx, (%rax)
movq 0x18(%rsp), %rax
addq $0x38, %rsp
retq
nop
// File: tomfunkhouser[P]gaps/pkgs/RNBasics/RNQueue.cpp
// Function: gaps::RNVQueue::Resize(int)
void RNVQueue::
Resize(int length)
{
  // Check if are expanding queue
  // Have to rework this if contract queue
  if (length > NAllocated()) {
    // Save number of entries allocated
    int oldnallocated = NAllocated();

    // Resize array of entries - we're reserving all allocated entries
    assert(entries.NAllocated() == entries.NEntries());
    entries.Resize(length);
    int newnallocated = entries.NAllocated();
    for (int i = 0; i < (newnallocated - oldnallocated); i++)
      entries.Insert(NULL);
    assert(entries.NAllocated() == entries.NEntries());
    
    // Check if need to unwrap some entries when array expands
    int oldnwrapped = head + nentries - oldnallocated;
    if (oldnwrapped > 0) {
      int nwrapped = head + nentries - entries.NEntries();
      int nunwrapped = oldnwrapped - nwrapped;
	    
      /* Shift newly unwrapped entries to end */
      if (nunwrapped > 0) entries.Shift(0, nunwrapped, oldnallocated);

      /* Shift still wrapped entries to start */
      if (nwrapped > 0) entries.Shift(nunwrapped, nwrapped, -nunwrapped);
    }
  }
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movl %esi, 0x2c(%rsp)
movq 0x30(%rsp), %rdi
movq %rdi, 0x8(%rsp)
movl 0x2c(%rsp), %eax
movl %eax, 0x10(%rsp)
callq 0x1a32f0
movl %eax, %ecx
movl 0x10(%rsp), %eax
cmpl %ecx, %eax
jle 0x1a2ee3
movq 0x8(%rsp), %rdi
callq 0x1a32f0
movq 0x8(%rsp), %rdi
movl %eax, 0x28(%rsp)
movl 0x2c(%rsp), %esi
callq 0x1a3560
movq 0x8(%rsp), %rdi
callq 0x412e0
movl %eax, 0x24(%rsp)
movl $0x0, 0x20(%rsp)
movl 0x20(%rsp), %eax
movl 0x24(%rsp), %ecx
subl 0x28(%rsp), %ecx
cmpl %ecx, %eax
jge 0x1a2e5f
movq 0x8(%rsp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x41320
movl 0x20(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x20(%rsp)
jmp 0x1a2e34
movq 0x8(%rsp), %rcx
movl 0x14(%rcx), %eax
addl 0x10(%rcx), %eax
subl 0x28(%rsp), %eax
movl %eax, 0x1c(%rsp)
cmpl $0x0, 0x1c(%rsp)
jle 0x1a2ee1
movq 0x8(%rsp), %rdi
movl 0x14(%rdi), %eax
addl 0x10(%rdi), %eax
movl %eax, 0x4(%rsp)
callq 0x2f1c0
movl %eax, %ecx
movl 0x4(%rsp), %eax
subl %ecx, %eax
movl %eax, 0x18(%rsp)
movl 0x1c(%rsp), %eax
subl 0x18(%rsp), %eax
movl %eax, 0x14(%rsp)
cmpl $0x0, 0x14(%rsp)
jle 0x1a2ec0
movq 0x8(%rsp), %rdi
movl 0x14(%rsp), %edx
movl 0x28(%rsp), %ecx
xorl %esi, %esi
callq 0x1a3690
cmpl $0x0, 0x18(%rsp)
jle 0x1a2edf
movq 0x8(%rsp), %rdi
movl 0x14(%rsp), %esi
movl 0x18(%rsp), %edx
xorl %ecx, %ecx
subl 0x14(%rsp), %ecx
callq 0x1a3690
jmp 0x1a2ee1
jmp 0x1a2ee3
addq $0x38, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/RNBasics/RNQueue.cpp
// Function: gaps::RNVQueue::Shift(int, int, int)
void RNVQueue::
Shift(int start, int length, int delta)
{
  /* Compute number of entries to shift */
  if ((delta < 0) && (start < -delta)) start = -delta;
  int nshift = nentries - start;
  if (delta > 0) nshift -= delta;
  if (nshift <= 0) return;
  if ((length > 0) && (length < nshift)) nshift = length;

  /* Shift queue entries */
  if (delta < 0) {
    for (int i = start; i < (start + nshift); i++) {
      EntryContents(KthEntry(i+delta)) = EntryContents(KthEntry(i));
    }
  }
  else if (delta > 0) {
    for (int i = (start + nshift - 1); i >= start; i--) {
      EntryContents(KthEntry(i+delta)) = EntryContents(KthEntry(i));
    }
  }
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movl %esi, 0x2c(%rsp)
movl %edx, 0x28(%rsp)
movl %ecx, 0x24(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x10(%rsp)
cmpl $0x0, 0x24(%rsp)
jge 0x1a2f2e
movl 0x2c(%rsp), %eax
xorl %ecx, %ecx
subl 0x24(%rsp), %ecx
cmpl %ecx, %eax
jge 0x1a2f2e
xorl %eax, %eax
subl 0x24(%rsp), %eax
movl %eax, 0x2c(%rsp)
movq 0x10(%rsp), %rax
movl 0x10(%rax), %eax
subl 0x2c(%rsp), %eax
movl %eax, 0x20(%rsp)
cmpl $0x0, 0x24(%rsp)
jle 0x1a2f53
movl 0x24(%rsp), %ecx
movl 0x20(%rsp), %eax
subl %ecx, %eax
movl %eax, 0x20(%rsp)
cmpl $0x0, 0x20(%rsp)
jg 0x1a2f5f
jmp 0x1a3069
cmpl $0x0, 0x28(%rsp)
jle 0x1a2f78
movl 0x28(%rsp), %eax
cmpl 0x20(%rsp), %eax
jge 0x1a2f78
movl 0x28(%rsp), %eax
movl %eax, 0x20(%rsp)
cmpl $0x0, 0x24(%rsp)
jge 0x1a2ff0
movl 0x2c(%rsp), %eax
movl %eax, 0x1c(%rsp)
movl 0x1c(%rsp), %eax
movl 0x2c(%rsp), %ecx
addl 0x20(%rsp), %ecx
cmpl %ecx, %eax
jge 0x1a2fee
movq 0x10(%rsp), %rdi
movl 0x1c(%rsp), %esi
callq 0x41250
movq 0x10(%rsp), %rdi
movq %rax, %rsi
callq 0x41240
movq 0x10(%rsp), %rdi
movq (%rax), %rax
movq %rax, 0x8(%rsp)
movl 0x1c(%rsp), %esi
addl 0x24(%rsp), %esi
callq 0x41250
movq 0x10(%rsp), %rdi
movq %rax, %rsi
callq 0x41240
movq 0x8(%rsp), %rcx
movq %rcx, (%rax)
movl 0x1c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x1a2f87
jmp 0x1a3069
cmpl $0x0, 0x24(%rsp)
jle 0x1a3067
movl 0x2c(%rsp), %eax
addl 0x20(%rsp), %eax
subl $0x1, %eax
movl %eax, 0x18(%rsp)
movl 0x18(%rsp), %eax
cmpl 0x2c(%rsp), %eax
jl 0x1a3065
movq 0x10(%rsp), %rdi
movl 0x18(%rsp), %esi
callq 0x41250
movq 0x10(%rsp), %rdi
movq %rax, %rsi
callq 0x41240
movq 0x10(%rsp), %rdi
movq (%rax), %rax
movq %rax, (%rsp)
movl 0x18(%rsp), %esi
addl 0x24(%rsp), %esi
callq 0x41250
movq 0x10(%rsp), %rdi
movq %rax, %rsi
callq 0x41240
movq (%rsp), %rcx
movq %rcx, (%rax)
movl 0x18(%rsp), %eax
addl $-0x1, %eax
movl %eax, 0x18(%rsp)
jmp 0x1a3006
jmp 0x1a3067
jmp 0x1a3069
addq $0x38, %rsp
retq
nop
// File: tomfunkhouser[P]gaps/pkgs/RNBasics/RNQueue.cpp
// Function: gaps::RNVQueue::InternalRemove(int)
void RNVQueue::
InternalRemove(int k) 
{
  // Check where entry is being removed
  if (k == 0) {
    // Remove from head by shifting head forward one
    head = (head + 1) % entries.NEntries();
  }
  else if (k < (nentries-1)) {
    // Remove from middle by shifting all subsequent entries back one
    Shift(k+1, 0, -1);
  }

  // Decrement number of entries
  nentries--;
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movl %esi, 0x1c(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x10(%rsp)
cmpl $0x0, 0x1c(%rsp)
jne 0x1a30b5
movq 0x10(%rsp), %rdi
movl 0x14(%rdi), %eax
addl $0x1, %eax
movl %eax, 0xc(%rsp)
callq 0x2f1c0
movl %eax, %ecx
movl 0xc(%rsp), %eax
cltd
idivl %ecx
movq 0x10(%rsp), %rax
movl %edx, 0x14(%rax)
jmp 0x1a30e2
movq 0x10(%rsp), %rcx
movl 0x1c(%rsp), %eax
movl 0x10(%rcx), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jge 0x1a30e0
movq 0x10(%rsp), %rdi
movl 0x1c(%rsp), %esi
addl $0x1, %esi
xorl %edx, %edx
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
callq 0x1a2ef0
jmp 0x1a30e2
movq 0x10(%rsp), %rax
movl 0x10(%rax), %ecx
addl $-0x1, %ecx
movl %ecx, 0x10(%rax)
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/RNBasics/RNQueue.cpp
// Function: gaps::RNVQueue::Pop()
void *RNVQueue::
Pop(void)
{
  // Check if there are any entries 
  if (IsEmpty()) {
    return NULL;
  }
  else {
    // Remove and return data from head of queue
    void *head = Head();
    RemoveHead();
    return head;
  }
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x3eb50
cmpl $0x0, %eax
je 0x1a3128
movq $0x0, 0x20(%rsp)
jmp 0x1a314b
movq 0x8(%rsp), %rdi
callq 0x411e0
movq 0x8(%rsp), %rdi
movq %rax, 0x10(%rsp)
callq 0x411c0
movq 0x10(%rsp), %rax
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rax
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/pkgs/RNBasics/RNQueue.cpp
// Function: gaps::RNVQueue::Reverse(int, int)
void RNVQueue::
Reverse(int start, int length)
{
  /* Compute number of entries to reverse */
  int nreverse = nentries - start;
  if (nreverse <= 0) return;
  if ((length > 0) && (length < nreverse)) nreverse = length;
  if (nreverse <= 0) return;

  // Reverse length at start
  int i, j;
  for (i = start, j = start + nreverse - 1; i < j; i++, j--) {
    RNSwap(KthEntry(i), KthEntry(j), NULL, sizeof(void *));
  }
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movl %esi, 0x2c(%rsp)
movl %edx, 0x28(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x10(%rsp)
movl 0x10(%rax), %eax
subl 0x2c(%rsp), %eax
movl %eax, 0x24(%rsp)
cmpl $0x0, 0x24(%rsp)
jg 0x1a3202
jmp 0x1a3294
cmpl $0x0, 0x28(%rsp)
jle 0x1a321b
movl 0x28(%rsp), %eax
cmpl 0x24(%rsp), %eax
jge 0x1a321b
movl 0x28(%rsp), %eax
movl %eax, 0x24(%rsp)
cmpl $0x0, 0x24(%rsp)
jg 0x1a3224
jmp 0x1a3294
movl 0x2c(%rsp), %eax
movl %eax, 0x20(%rsp)
movl 0x2c(%rsp), %eax
addl 0x24(%rsp), %eax
subl $0x1, %eax
movl %eax, 0x1c(%rsp)
movl 0x20(%rsp), %eax
cmpl 0x1c(%rsp), %eax
jge 0x1a3294
movq 0x10(%rsp), %rdi
movl 0x20(%rsp), %esi
callq 0x41250
movq 0x10(%rsp), %rdi
movq %rax, 0x8(%rsp)
movl 0x1c(%rsp), %esi
callq 0x41250
movq 0x8(%rsp), %rdi
movq %rax, %rsi
xorl %eax, %eax
movl %eax, %edx
movl $0x8, %ecx
callq 0x1a72d0
movl 0x20(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x20(%rsp)
movl 0x1c(%rsp), %eax
addl $-0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x1a323b
addq $0x38, %rsp
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/RNBasics/RNQueue.cpp
// Function: gaps::RNVQueue::operator=(gaps::RNVQueue const&)
RNVQueue& RNVQueue::
operator=(const RNVQueue& queue)
{
  // Assign queue 
  entries = queue.entries;
  nentries = queue.nentries;
  head = queue.head;

  // Return queue
  return *this;
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq %rsi, 0x8(%rsp)
movq 0x10(%rsp), %rdi
movq %rdi, (%rsp)
movq 0x8(%rsp), %rsi
callq 0x1a3380
movq (%rsp), %rax
movq 0x8(%rsp), %rcx
movl 0x10(%rcx), %ecx
movl %ecx, 0x10(%rax)
movq 0x8(%rsp), %rcx
movl 0x14(%rcx), %ecx
movl %ecx, 0x14(%rax)
addq $0x18, %rsp
retq
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: main
int main(int argc, char **argv)
{
  // Parse program arguments
  if (!ParseArgs(argc, argv)) exit(-1);

  // Read scene
  if (!ReadScene(input_scene_filename)) exit(-1);

  // Read cameras
  if (input_cameras_filename) {
    if (!ReadCameras(input_cameras_filename)) exit(-1);
  }

  // Read categories
  if (input_categories_filename) {
    if (!ReadCategories(input_categories_filename)) exit(-1);
  }

  // Read points
  if (input_points_filename) {
    if (!ReadPoints(input_points_filename)) exit(-1);
  }

  // Create and write new cameras 
  if (mesa) CreateAndWriteCamerasWithMesa();
  else if (glut) CreateAndWriteCamerasWithGlut();
  else CreateAndWriteCameras();

  // Return success 
  return 0;
}

// Assembly:
subq $0x18, %rsp
movl $0x0, 0x14(%rsp)
movl %edi, 0x10(%rsp)
movq %rsi, 0x8(%rsp)
movl 0x10(%rsp), %edi
movq 0x8(%rsp), %rsi
callq 0x280c0
cmpl $0x0, %eax
jne 0x27ff2
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
movq 0x207b97(%rip), %rdi    # 0x22fb90
callq 0x28d30
cmpq $0x0, %rax
jne 0x2800e
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
cmpq $0x0, 0x207b82(%rip)    # 0x22fb98
je 0x28035
movq 0x207b79(%rip), %rdi    # 0x22fb98
callq 0x28f40
cmpl $0x0, %eax
jne 0x28033
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
jmp 0x28035
cmpq $0x0, 0x207b63(%rip)    # 0x22fba0
je 0x2805c
movq 0x207b5a(%rip), %rdi    # 0x22fba0
callq 0x29360
cmpl $0x0, %eax
jne 0x2805a
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
jmp 0x2805c
cmpq $0x0, 0x207b44(%rip)    # 0x22fba8
je 0x28083
movq 0x207b3b(%rip), %rdi    # 0x22fba8
callq 0x29400
cmpl $0x0, %eax
jne 0x28081
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
jmp 0x28083
cmpl $0x0, 0x207b26(%rip)    # 0x22fbb0
je 0x28093
callq 0x29570
jmp 0x280aa
cmpl $0x0, 0x2019e6(%rip)    # 0x229a80
je 0x280a3
callq 0x29590
jmp 0x280a8
callq 0x29610
jmp 0x280aa
xorl %eax, %eax
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: ReadPoints(char const*)
static int
ReadPoints(const char *filename)
{
  // Start statistics
  RNTime start_time;
  start_time.Read();

  // Allocate points
  points = new R3PointSet();
  if (!points) {
    RNFail("Unable to allocate points for %s\n", filename);
    return 0;
  }
  
  // Read points
  if (!points->ReadFile(filename)) {
    RNFail("Unable to read points file %s\n", filename);
    delete points;
    return 0;
  }

  // Print statistics
  if (print_verbose) {
    printf("Read points from %s ...\n", filename);
    printf("  Time = %.2f seconds\n", start_time.Elapsed());
    printf("  # Points = %d\n", points->NPoints());
    fflush(stdout);
  }

  // Return success
  return 1;
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
leaq 0x28(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x11bad0
movq 0x8(%rsp), %rdi
callq 0x321a0
movl $0x150, %edi            # imm = 0x150
callq 0x239b0
movq %rax, %rdi
movq %rdi, %rax
movq %rax, 0x10(%rsp)
callq 0xdc750
jmp 0x2943e
movq 0x10(%rsp), %rax
movq %rax, 0x2067f6(%rip)    # 0x22fc40
cmpq $0x0, 0x2067ee(%rip)    # 0x22fc40
jne 0x29496
movq 0x38(%rsp), %rsi
leaq 0x1920ce(%rip), %rdi    # 0x1bb52e
movb $0x0, %al
callq 0x120a50
movl $0x0, 0x44(%rsp)
jmp 0x29558
movq 0x10(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x20(%rsp)
movl %eax, 0x1c(%rsp)
movl $0x150, %esi            # imm = 0x150
callq 0x239d0
jmp 0x29561
movq 0x2067a3(%rip), %rdi    # 0x22fc40
movq 0x38(%rsp), %rsi
callq 0xde3e0
cmpl $0x0, %eax
jne 0x294f1
movq 0x38(%rsp), %rsi
leaq 0x192098(%rip), %rdi    # 0x1bb550
movb $0x0, %al
callq 0x120a50
movq 0x20677a(%rip), %rax    # 0x22fc40
movq %rax, (%rsp)
cmpq $0x0, %rax
je 0x294e7
movq (%rsp), %rdi
callq 0xdca40
movq (%rsp), %rdi
movl $0x150, %esi            # imm = 0x150
callq 0x239d0
movl $0x0, 0x44(%rsp)
jmp 0x29558
cmpl $0x0, 0x2066bc(%rip)    # 0x22fbb4
je 0x29550
movq 0x38(%rsp), %rsi
leaq 0x192069(%rip), %rdi    # 0x1bb56f
movb $0x0, %al
callq 0x23090
leaq 0x28(%rsp), %rdi
callq 0x11bb90
leaq 0x191f1c(%rip), %rdi    # 0x1bb43a
movb $0x1, %al
callq 0x23090
movq 0x206714(%rip), %rdi    # 0x22fc40
callq 0x32400
movl %eax, %esi
leaq 0x19204e(%rip), %rdi    # 0x1bb588
movb $0x0, %al
callq 0x23090
movq 0x1ffa48(%rip), %rax    # 0x228f90
movq (%rax), %rdi
callq 0x23bc0
movl $0x1, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
movq 0x20(%rsp), %rdi
callq 0x24250
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: CreateAndWriteCameras()
static void
CreateAndWriteCameras(void)
{
  // Create cameras
  if (create_object_cameras) CreateObjectCameras();
  if (create_interior_cameras) CreateInteriorCameras();
  if (create_surface_cameras) CreateSurfaceCameras();
  if (create_world_in_hand_cameras) CreateWorldInHandCameras();
  if (create_orbit_cameras) CreateOrbitCameras();
  if (create_lookat_cameras) CreateLookAtCameras();

  // Create specialized cameras (for SUNCG)
  if (create_room_cameras) CreateRoomCameras();
  if (create_path_in_room_cameras) CreatePathInRoomCameras();

  // Create trajectory from cameras
  if (interpolate_camera_trajectory) {
    if (!InterpolateCameraTrajectory(interpolation_step)) exit(-1);
  }
  else {
    SortCameras();
  }

  // Write cameras
  WriteCameras();

  // Exit program
  exit(0);
}

// Assembly:
pushq %rax
cmpl $0x0, 0x2065f0(%rip)    # 0x22fc08
je 0x2961f
callq 0x296c0
cmpl $0x0, 0x2065ee(%rip)    # 0x22fc14
je 0x2962d
callq 0x2a060
cmpl $0x0, 0x2065e4(%rip)    # 0x22fc18
je 0x2963b
callq 0x2ac00
cmpl $0x0, 0x2065e2(%rip)    # 0x22fc24
je 0x29649
callq 0x2b6e0
cmpl $0x0, 0x2065bc(%rip)    # 0x22fc0c
je 0x29657
callq 0x2bc40
cmpl $0x0, 0x2065ca(%rip)    # 0x22fc28
je 0x29665
callq 0x2c0e0
cmpl $0x0, 0x2065b0(%rip)    # 0x22fc1c
je 0x29673
callq 0x2c6d0
cmpl $0x0, 0x2065a6(%rip)    # 0x22fc20
je 0x29681
callq 0x2d310
cmpl $0x0, 0x206558(%rip)    # 0x22fbe0
je 0x296a8
movsd 0x20043e(%rip), %xmm0   # 0x229ad0
callq 0x2ddc0
cmpl $0x0, %eax
jne 0x296a6
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
jmp 0x296ad
callq 0x2e880
callq 0x2e910
xorl %edi, %edi
callq 0x23c20
nopl (%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: SortCameras()
static int
SortCameras(void)
{
  // Start statistics
  RNTime start_time;
  start_time.Read();

  // Sort the cameras
  cameras.Sort(R3CompareCameras);

  // Print statistics
  if (print_verbose) {
    printf("Sorted cameras ...\n");
    printf("  Time = %.2f seconds\n", start_time.Elapsed());
    printf("  # Cameras = %d\n", cameras.NEntries());
    fflush(stdout);
  }

  // Return success
  return 1;
}

// Assembly:
subq $0x18, %rsp
leaq 0x8(%rsp), %rdi
callq 0x11bad0
leaq 0x8(%rsp), %rdi
callq 0x321a0
leaq 0x2012e1(%rip), %rdi    # 0x22fb80
leaq 0x3a38a(%rip), %rsi     # 0x68c30
callq 0x11cd60
cmpl $0x0, 0x201302(%rip)    # 0x22fbb4
je 0x2e905
leaq 0x18cf71(%rip), %rdi    # 0x1bb82c
movb $0x0, %al
callq 0x23090
leaq 0x8(%rsp), %rdi
callq 0x11bb90
leaq 0x18cb67(%rip), %rdi    # 0x1bb43a
movb $0x1, %al
callq 0x23090
leaq 0x20129f(%rip), %rdi    # 0x22fb80
callq 0x32280
movl %eax, %esi
leaq 0x18cc10(%rip), %rdi    # 0x1bb4ff
movb $0x0, %al
callq 0x23090
movq 0x1fa693(%rip), %rax    # 0x228f90
movq (%rax), %rdi
callq 0x23bc0
movl $0x1, %eax
addq $0x18, %rsp
retq
nop
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: WriteCameras()
static int
WriteCameras(void)
{
  // Write cameras 
  if (output_cameras_filename) {
    if (!WriteCameras(output_cameras_filename)) exit(-1);
  }
  
  // Write camera extrinsics 
  if (output_camera_extrinsics_filename) {
    if (!WriteCameraExtrinsics(output_camera_extrinsics_filename)) exit(-1);
  }
  
  // Write camera intrinsics 
  if (output_camera_intrinsics_filename) {
    if (!WriteCameraIntrinsics(output_camera_intrinsics_filename)) exit(-1);
  }

  // Write camera names 
  if (output_camera_names_filename) {
    if (!WriteCameraNames(output_camera_names_filename)) exit(-1);
  }

  // Write node names
  if (output_nodes_filename) {
    if (!WriteNodeNames(output_nodes_filename)) exit(-1);
  }

  // Return success
  return 1;
}

// Assembly:
pushq %rax
cmpq $0x0, 0x201317(%rip)    # 0x22fc30
je 0x2e938
movq 0x20130e(%rip), %rdi    # 0x22fc30
callq 0x31640
cmpl $0x0, %eax
jne 0x2e936
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
jmp 0x2e938
cmpq $0x0, 0x201280(%rip)    # 0x22fbc0
je 0x2e95f
movq 0x201277(%rip), %rdi    # 0x22fbc0
callq 0x31960
cmpl $0x0, %eax
jne 0x2e95d
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
jmp 0x2e95f
cmpq $0x0, 0x201261(%rip)    # 0x22fbc8
je 0x2e986
movq 0x201258(%rip), %rdi    # 0x22fbc8
callq 0x31cc0
cmpl $0x0, %eax
jne 0x2e984
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
jmp 0x2e986
cmpq $0x0, 0x201242(%rip)    # 0x22fbd0
je 0x2e9ad
movq 0x201239(%rip), %rdi    # 0x22fbd0
callq 0x31ea0
cmpl $0x0, %eax
jne 0x2e9ab
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
jmp 0x2e9ad
cmpq $0x0, 0x201223(%rip)    # 0x22fbd8
je 0x2e9d4
movq 0x20121a(%rip), %rdi    # 0x22fbd8
callq 0x32000
cmpl $0x0, %eax
jne 0x2e9d2
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x23c20
jmp 0x2e9d4
movl $0x1, %eax
popq %rcx
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: IsObject(gaps::R3SceneNode*)
static RNBoolean
IsObject(R3SceneNode *node)
{
  // Check name
  if (!node->Name()) return 0;

  // Check category identifier
  if (input_categories_filename) {
    // Check if object with category
    if (strncmp(node->Name(), "Model#", 6)) return 0;
    
    // Get category identifier
    R3SceneNode *ancestor = node;
    const char *category_identifier = NULL;
    while (!category_identifier && ancestor) {
      category_identifier = node->Info("empty_struct_obj");
      ancestor = ancestor->Parent();
    }

    // Check category identifier
    if (category_identifier) {
      if (strcmp(category_identifier, "2")) return 0;
    }
  }

  // Passed all tests
  return 1;
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rdi
callq 0x32460
cmpq $0x0, %rax
jne 0x2ea06
movl $0x0, 0x24(%rsp)
jmp 0x2ead7
cmpq $0x0, 0x201192(%rip)    # 0x22fba0
je 0x2eacf
movq 0x18(%rsp), %rdi
callq 0x32460
movq %rax, %rdi
leaq 0x18cc05(%rip), %rsi    # 0x1bb62d
movl $0x6, %edx
callq 0x23430
cmpl $0x0, %eax
je 0x2ea44
movl $0x0, 0x24(%rsp)
jmp 0x2ead7
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movq $0x0, 0x8(%rsp)
xorl %eax, %eax
cmpq $0x0, 0x8(%rsp)
movb %al, 0x7(%rsp)
jne 0x2ea72
cmpq $0x0, 0x10(%rsp)
setne %al
movb %al, 0x7(%rsp)
movb 0x7(%rsp), %al
testb $0x1, %al
jne 0x2ea7c
jmp 0x2eaa3
movq 0x18(%rsp), %rdi
leaq 0x18cbac(%rip), %rsi    # 0x1bb634
callq 0x32620
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
callq 0x324e0
movq %rax, 0x10(%rsp)
jmp 0x2ea57
cmpq $0x0, 0x8(%rsp)
je 0x2eacd
movq 0x8(%rsp), %rdi
leaq 0x1950c9(%rip), %rsi    # 0x1c3b80
callq 0x23e90
cmpl $0x0, %eax
je 0x2eacb
movl $0x0, 0x24(%rsp)
jmp 0x2ead7
jmp 0x2eacd
jmp 0x2eacf
movl $0x1, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: RenderImageWithOpenGL(gaps::R2Grid&, gaps::R3Camera const&, gaps::R3Scene*, gaps::R3SceneNode*, gaps::R3SceneNode*, int)
static void 
RenderImageWithOpenGL(R2Grid& image, const R3Camera& camera, R3Scene *scene, R3SceneNode *root_node, R3SceneNode *selected_node, int image_type)
{
  // Clear window
  glClearColor(0.0, 0.0, 0.0, 1.0);
  glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);

  // Initialize transformation
  glMatrixMode(GL_MODELVIEW);
  glLoadIdentity();

  // Load camera and viewport
  camera.Load();
  glViewport(0, 0, width, height);

  // Initialize graphics modes  
  glEnable(GL_DEPTH_TEST);

  // Draw scene
  R3null_material.Draw();
  DrawNodeWithOpenGL(scene, root_node, selected_node, image_type);
  R3null_material.Draw();

  // Read frame buffer into image
  CaptureScalar(image);

  // Compensate for rendering background black
  image.Substitute(0, R2_GRID_UNKNOWN_VALUE);
  if (image_type == NODE_INDEX_IMAGE) image.Subtract(1.0);
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x20(%rsp)
movq %rcx, 0x18(%rsp)
movq %r8, 0x10(%rsp)
movl %r9d, 0xc(%rsp)
xorps %xmm2, %xmm2
movss 0x18b9db(%rip), %xmm3   # 0x1bb0a8
movaps %xmm2, %xmm0
movaps %xmm2, %xmm1
callq 0x23fa0
movl $0x4100, %edi           # imm = 0x4100
callq 0x23200
movl $0x1700, %edi           # imm = 0x1700
callq 0x23e20
callq 0x23da0
movq 0x28(%rsp), %rdi
xorl %esi, %esi
callq 0x688e0
movl 0x1fa385(%rip), %edx    # 0x229a88
movl 0x1fa383(%rip), %ecx    # 0x229a8c
xorl %esi, %esi
movl %esi, %edi
callq 0x23220
movl $0xb71, %edi            # imm = 0xB71
callq 0x238e0
leaq 0x20696d(%rip), %rdi    # 0x236090
xorl %esi, %esi
callq 0x6e2b0
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rsi
movq 0x10(%rsp), %rdx
movl 0xc(%rsp), %ecx
callq 0x2fa10
leaq 0x206947(%rip), %rdi    # 0x236090
xorl %esi, %esi
callq 0x6e2b0
movq 0x30(%rsp), %rdi
callq 0x2fc00
movq 0x30(%rsp), %rdi
xorps %xmm0, %xmm0
movsd 0x18b926(%rip), %xmm1   # 0x1bb090
callq 0xf9520
cmpl $0x0, 0xc(%rsp)
jne 0x2f788
movq 0x30(%rsp), %rdi
movsd 0x18b905(%rip), %xmm0   # 0x1bb088
callq 0xf9720
addq $0x38, %rsp
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: CaptureScalar(gaps::R2Grid&)
static int
CaptureScalar(R2Grid& scalar_image)
{
  // Set packing parameters for glReadPixels
  if ((width % 4) != 0) glPixelStorei(GL_PACK_ALIGNMENT, 1);

  // Capture rgb pixels
  unsigned char *pixels = new unsigned char [ 3 * width * height ];
  glReadPixels(0, 0, width, height, GL_RGB, GL_UNSIGNED_BYTE, pixels);

  // Fill scalar image
  unsigned char *pixelp = pixels;
  for (int iy = 0; iy < height; iy++) {
    for (int ix = 0; ix < width; ix++) {
      unsigned int value = 0;
      value |= (*pixelp++ << 16) & 0xFF0000;
      value |= (*pixelp++ <<  8) & 0x00FF00;
      value |= (*pixelp++      ) & 0x0000FF;
      scalar_image.SetGridValue(ix, iy, value);
    }
  }

  // Delete rgb pixels
  delete [] pixels;
  
  // Return success
  return 1;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movl 0x1f9e79(%rip), %eax    # 0x229a88
movl $0x4, %ecx
cltd
idivl %ecx
cmpl $0x0, %edx
je 0x2fc2b
movl $0xd05, %edi            # imm = 0xD05
movl $0x1, %esi
callq 0x23460
imull $0x3, 0x1f9e56(%rip), %eax # 0x229a88
imull 0x1f9e53(%rip), %eax    # 0x229a8c
movslq %eax, %rdi
callq 0x23040
movq %rax, 0x28(%rsp)
movl 0x1f9e3c(%rip), %edx    # 0x229a88
movl 0x1f9e3a(%rip), %ecx    # 0x229a8c
movq 0x28(%rsp), %rax
xorl %esi, %esi
movl $0x1907, %r8d           # imm = 0x1907
movl $0x1401, %r9d           # imm = 0x1401
movl %esi, %edi
movq %rax, (%rsp)
callq 0x23410
movq 0x28(%rsp), %rax
movq %rax, 0x20(%rsp)
movl $0x0, 0x1c(%rsp)
movl 0x1c(%rsp), %eax
cmpl 0x1f9e00(%rip), %eax    # 0x229a8c
jge 0x2fd4c
movl $0x0, 0x18(%rsp)
movl 0x18(%rsp), %eax
cmpl 0x1f9de4(%rip), %eax    # 0x229a88
jge 0x2fd3a
movl $0x0, 0x14(%rsp)
movq 0x20(%rsp), %rax
movq %rax, %rcx
incq %rcx
movq %rcx, 0x20(%rsp)
movzbl (%rax), %ecx
shll $0x10, %ecx
movl 0x14(%rsp), %eax
orl %ecx, %eax
movl %eax, 0x14(%rsp)
movq 0x20(%rsp), %rax
movq %rax, %rcx
incq %rcx
movq %rcx, 0x20(%rsp)
movzbl (%rax), %ecx
shll $0x8, %ecx
movl 0x14(%rsp), %eax
orl %ecx, %eax
movl %eax, 0x14(%rsp)
movq 0x20(%rsp), %rax
movq %rax, %rcx
incq %rcx
movq %rcx, 0x20(%rsp)
movzbl (%rax), %ecx
movl 0x14(%rsp), %eax
orl %ecx, %eax
movl %eax, 0x14(%rsp)
movq 0x30(%rsp), %rdi
movl 0x18(%rsp), %esi
movl 0x1c(%rsp), %edx
movl 0x14(%rsp), %eax
cvtsi2sd %rax, %xmm0
callq 0x33680
movl 0x18(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x18(%rsp)
jmp 0x2fc9a
jmp 0x2fd3c
movl 0x1c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x2fc82
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
cmpq $0x0, %rax
je 0x2fd66
movq 0x8(%rsp), %rdi
callq 0x23d70
movl $0x1, %eax
addq $0x38, %rsp
retq
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: IsDifferentCameraOrientation(Camera*, Camera*, void*)
static int
IsDifferentCameraOrientation(Camera *camera1, Camera *camera2, void *data)
{
  // Check towards angle
  R3Vector towards1 = camera1->Towards();  
  R3Vector towards2 = camera2->Towards();
  if (R3InteriorAngle(towards1, towards2) > angle_sampling) return 1;

  // Check up angle
  R3Vector up1 = camera1->Up();  
  R3Vector up2 = camera2->Up();
  if (R3InteriorAngle(up1, up2) > angle_sampling) return 1;

  // Cameras overlap
  return 0;
}

// Assembly:
subq $0x88, %rsp
movq %rdi, 0x78(%rsp)
movq %rsi, 0x70(%rsp)
movq %rdx, 0x68(%rsp)
movq 0x78(%rsp), %rsi
leaq 0x50(%rsp), %rdi
callq 0x34a10
movq 0x70(%rsp), %rsi
leaq 0x38(%rsp), %rdi
callq 0x34a10
leaq 0x50(%rsp), %rdi
leaq 0x38(%rsp), %rsi
callq 0x86dd0
ucomisd 0x1ffe05(%rip), %xmm0   # 0x22fc00
jbe 0x2fe0a
movl $0x1, 0x84(%rsp)
jmp 0x2fe69
movq 0x78(%rsp), %rdi
callq 0x34a60
movq %rax, %rsi
leaq 0x20(%rsp), %rdi
callq 0xdb0e0
movq 0x70(%rsp), %rdi
callq 0x34a60
movq %rax, %rsi
leaq 0x8(%rsp), %rdi
callq 0xdb0e0
leaq 0x20(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x86dd0
ucomisd 0x1ffdb1(%rip), %xmm0   # 0x22fc00
jbe 0x2fe5e
movl $0x1, 0x84(%rsp)
jmp 0x2fe69
movl $0x0, 0x84(%rsp)
movl 0x84(%rsp), %eax
addq $0x88, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: IsRoom(gaps::R3SceneNode*)
static RNBoolean
IsRoom(R3SceneNode *node)
{
  // Check if labeled
  if (input_categories_filename) {
    // Check if node is labeled as a room
    if (!node->Name()) return 0;
    if (strncmp(node->Name(), "Room#", 5)) return 0;
  }
  else {
    // If no "rooms", then include only root node
    if (node->Parent()) return 0;
  }

  // Passed all tests
  return 1;
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x8(%rsp)
cmpq $0x0, 0x1ffd0f(%rip)    # 0x22fba0
je 0x2fedc
movq 0x8(%rsp), %rdi
callq 0x32460
cmpq $0x0, %rax
jne 0x2fead
movl $0x0, 0x14(%rsp)
jmp 0x2ff00
movq 0x8(%rsp), %rdi
callq 0x32460
movq %rax, %rdi
leaq 0x18b8c1(%rip), %rsi    # 0x1bb782
movl $0x5, %edx
callq 0x23430
cmpl $0x0, %eax
je 0x2feda
movl $0x0, 0x14(%rsp)
jmp 0x2ff00
jmp 0x2fef8
movq 0x8(%rsp), %rdi
callq 0x324e0
cmpq $0x0, %rax
je 0x2fef6
movl $0x0, 0x14(%rsp)
jmp 0x2ff00
jmp 0x2fef8
movl $0x1, 0x14(%rsp)
movl 0x14(%rsp), %eax
addq $0x18, %rsp
retq
nopl (%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: FindIndexOfRandomPoint(gaps::R2Grid const&)
static int
FindIndexOfRandomPoint(const R2Grid& grid)
{
  // Choose random point in connected component
  int random_point_counter = (int) (RNRandomScalar() * grid.Cardinality());
  for (int i = 0; i < grid.NEntries(); i++) {
    if (grid.GridValue(i) == R2_GRID_UNKNOWN_VALUE) continue;
    if (--random_point_counter == 0) return i;
  }

  // Should not get here
  return -1;
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
callq 0x11f4d0
movsd %xmm0, 0x8(%rsp)
movq 0x18(%rsp), %rdi
callq 0xf2bb0
movsd 0x8(%rsp), %xmm0
cvtsi2sd %eax, %xmm1
mulsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, 0x14(%rsp)
movl $0x0, 0x10(%rsp)
movl 0x10(%rsp), %eax
movl %eax, 0x4(%rsp)
movq 0x18(%rsp), %rdi
callq 0x33520
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jge 0x31051
movq 0x18(%rsp), %rdi
movl 0x10(%rsp), %esi
callq 0x33540
movsd 0x18a072(%rip), %xmm1   # 0x1bb090
ucomisd %xmm1, %xmm0
jne 0x31028
jp 0x31028
jmp 0x31044
movl 0x14(%rsp), %eax
addl $-0x1, %eax
movl %eax, 0x14(%rsp)
cmpl $0x0, %eax
jne 0x31042
movl 0x10(%rsp), %eax
movl %eax, 0x24(%rsp)
jmp 0x31059
jmp 0x31044
movl 0x10(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x10(%rsp)
jmp 0x30fec
movl $0xffffffff, 0x24(%rsp) # imm = 0xFFFFFFFF
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: WriteCameraIntrinsics(char const*)
static int
WriteCameraIntrinsics(const char *filename)
{
  // Start statistics
  RNTime start_time;
  start_time.Read();

  // Open file
  FILE *fp = fopen(filename, "w");
  if (!fp) {
    RNFail("Unable to open camera intrinsics file %s\n", filename);
    return 0;
  }

  // Get center of image
  RNScalar cx = 0.5 * width;
  RNScalar cy = 0.5 * height;

  // Write file
  for (int i = 0; i < cameras.NEntries(); i++) {
    Camera *camera = cameras.Kth(i);
    RNScalar fx = 0.5 * width / tan(camera->XFOV());
    RNScalar fy = 0.5 * height / tan(camera->YFOV());
    fprintf(fp, "%g 0 %g   0 %g %g  0 0 1\n", fx, cx, fy, cy);
  }

  // Close file
  fclose(fp);

  // Print statistics
  if (print_verbose) {
    printf("Wrote camera intrinsics to %s ...\n", filename);
    printf("  Time = %.2f seconds\n", start_time.Elapsed());
    fflush(stdout);
  }

  // Return success
  return 1;
}

// Assembly:
subq $0x78, %rsp
movq %rdi, 0x68(%rsp)
leaq 0x58(%rsp), %rdi
callq 0x11bad0
leaq 0x58(%rsp), %rdi
callq 0x321a0
movq 0x68(%rsp), %rdi
leaq 0x18cc91(%rip), %rsi    # 0x1be97a
callq 0x23bd0
movq %rax, 0x50(%rsp)
cmpq $0x0, 0x50(%rsp)
jne 0x31d1b
movq 0x68(%rsp), %rsi
leaq 0x189bf0(%rip), %rdi    # 0x1bb8f7
movb $0x0, %al
callq 0x120a50
movl $0x0, 0x74(%rsp)
jmp 0x31e96
cvtsi2sdl 0x1f7d65(%rip), %xmm1 # 0x229a88
movsd 0x189305(%rip), %xmm0   # 0x1bb030
mulsd %xmm1, %xmm0
movsd %xmm0, 0x48(%rsp)
cvtsi2sdl 0x1f7d4f(%rip), %xmm1 # 0x229a8c
movsd 0x1892eb(%rip), %xmm0   # 0x1bb030
mulsd %xmm1, %xmm0
movsd %xmm0, 0x40(%rsp)
movl $0x0, 0x3c(%rsp)
movl 0x3c(%rsp), %eax
movl %eax, 0x1c(%rsp)
leaq 0x1fde1a(%rip), %rdi    # 0x22fb80
callq 0x32280
movl %eax, %ecx
movl 0x1c(%rsp), %eax
cmpl %ecx, %eax
jge 0x31e41
movl 0x3c(%rsp), %esi
leaq 0x1fddfc(%rip), %rdi    # 0x22fb80
callq 0x36c40
movq %rax, 0x30(%rsp)
cvtsi2sdl 0x1f7cf2(%rip), %xmm1 # 0x229a88
movsd 0x189292(%rip), %xmm0   # 0x1bb030
mulsd %xmm1, %xmm0
movsd %xmm0, 0x8(%rsp)
movq 0x30(%rsp), %rdi
callq 0x36c00
callq 0x234f0
movaps %xmm0, %xmm1
movsd 0x8(%rsp), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, 0x28(%rsp)
cvtsi2sdl 0x1f7cba(%rip), %xmm1 # 0x229a8c
movsd 0x189256(%rip), %xmm0   # 0x1bb030
mulsd %xmm1, %xmm0
movsd %xmm0, 0x10(%rsp)
movq 0x30(%rsp), %rdi
callq 0x36c10
callq 0x234f0
movaps %xmm0, %xmm1
movsd 0x10(%rsp), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, 0x20(%rsp)
movq 0x50(%rsp), %rdi
movsd 0x28(%rsp), %xmm0
movsd 0x48(%rsp), %xmm1
movsd 0x20(%rsp), %xmm2
movsd 0x40(%rsp), %xmm3
leaq 0x189af7(%rip), %rsi    # 0x1bb921
movb $0x4, %al
callq 0x23f00
movl 0x3c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x3c(%rsp)
jmp 0x31d57
movq 0x50(%rsp), %rdi
callq 0x239a0
cmpl $0x0, 0x1fdd62(%rip)    # 0x22fbb4
je 0x31e8e
movq 0x68(%rsp), %rsi
leaq 0x189adb(%rip), %rdi    # 0x1bb93b
movb $0x0, %al
callq 0x23090
leaq 0x58(%rsp), %rdi
callq 0x11bb90
leaq 0x1895c2(%rip), %rdi    # 0x1bb43a
movb $0x1, %al
callq 0x23090
movq 0x1f710a(%rip), %rax    # 0x228f90
movq (%rax), %rdi
callq 0x23bc0
movl $0x1, 0x74(%rsp)
movl 0x74(%rsp), %eax
addq $0x78, %rsp
retq
nop
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: WriteCameraNames(char const*)
static int
WriteCameraNames(const char *filename)
{
  // Start statistics
  RNTime start_time;
  start_time.Read();

  // Open file
  FILE *fp = fopen(filename, "w");
  if (!fp) {
    RNFail("Unable to open camera names file %s\n", filename);
    return 0;
  }

  // Write file
  for (int i = 0; i < cameras.NEntries(); i++) {
    Camera *camera = cameras.Kth(i);
    fprintf(fp, "%s\n", (camera->name) ? camera->name : "-");
  }

  // Close file
  fclose(fp);

  // Print statistics
  if (print_verbose) {
    printf("Wrote camera names to %s ...\n", filename);
    printf("  Time = %.2f seconds\n", start_time.Elapsed());
    fflush(stdout);
  }

  // Return success
  return 1;
}

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x48(%rsp)
leaq 0x38(%rsp), %rdi
callq 0x11bad0
leaq 0x38(%rsp), %rdi
callq 0x321a0
movq 0x48(%rsp), %rdi
leaq 0x18cab1(%rip), %rsi    # 0x1be97a
callq 0x23bd0
movq %rax, 0x30(%rsp)
cmpq $0x0, 0x30(%rsp)
jne 0x31efb
movq 0x48(%rsp), %rsi
leaq 0x189a77(%rip), %rdi    # 0x1bb95e
movb $0x0, %al
callq 0x120a50
movl $0x0, 0x54(%rsp)
jmp 0x31fed
movl $0x0, 0x2c(%rsp)
movl 0x2c(%rsp), %eax
movl %eax, 0x1c(%rsp)
leaq 0x1fdc6e(%rip), %rdi    # 0x22fb80
callq 0x32280
movl %eax, %ecx
movl 0x1c(%rsp), %eax
cmpl %ecx, %eax
jge 0x31f98
movl 0x2c(%rsp), %esi
leaq 0x1fdc54(%rip), %rdi    # 0x22fb80
callq 0x36c40
movq %rax, 0x20(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rax
cmpq $0x0, 0x90(%rax)
je 0x31f62
movq 0x20(%rsp), %rax
movq 0x90(%rax), %rax
movq %rax, 0x8(%rsp)
jmp 0x31f70
leaq 0x189699(%rip), %rax    # 0x1bb602
movq %rax, 0x8(%rsp)
jmp 0x31f70
movq 0x10(%rsp), %rdi
movq 0x8(%rsp), %rdx
leaq 0x18cb60(%rip), %rsi    # 0x1beae1
movb $0x0, %al
callq 0x23f00
movl 0x2c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x2c(%rsp)
jmp 0x31f03
movq 0x30(%rsp), %rdi
callq 0x239a0
cmpl $0x0, 0x1fdc0b(%rip)    # 0x22fbb4
je 0x31fe5
movq 0x48(%rsp), %rsi
leaq 0x1899cc(%rip), %rdi    # 0x1bb983
movb $0x0, %al
callq 0x23090
leaq 0x38(%rsp), %rdi
callq 0x11bb90
leaq 0x18946b(%rip), %rdi    # 0x1bb43a
movb $0x1, %al
callq 0x23090
movq 0x1f6fb3(%rip), %rax    # 0x228f90
movq (%rax), %rdi
callq 0x23bc0
movl $0x1, 0x54(%rsp)
movl 0x54(%rsp), %eax
addq $0x58, %rsp
retq
nopw %cs:(%rax,%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/scn2cam.cpp
// Function: WriteNodeNames(char const*)
static int
WriteNodeNames(const char *filename)
{
  // Start statistics
  RNTime start_time;
  start_time.Read();

  // Open file
  FILE *fp = fopen(filename, "w");
  if (!fp) {
    RNFail("Unable to open node name file %s\n", filename);
    return 0;
  }

  // Write file
  for (int i = 0; i < scene->NNodes(); i++) {
    R3SceneNode *node = scene->Node(i);
    const char *name = (node->Name()) ? node->Name() : "-";
    fprintf(fp, "%d %s\n", i+1, name);
  }

  // Close file
  fclose(fp);

  // Print statistics
  if (print_verbose) {
    printf("Wrote node names to %s ...\n", filename);
    printf("  Time = %.2f seconds\n", start_time.Elapsed());
    printf("  # Nodes = %d\n", scene->NNodes());
    fflush(stdout);
  }

  // Return success
  return 1;
}

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x48(%rsp)
leaq 0x38(%rsp), %rdi
callq 0x11bad0
leaq 0x38(%rsp), %rdi
callq 0x321a0
movq 0x48(%rsp), %rdi
leaq 0x18c951(%rip), %rsi    # 0x1be97a
callq 0x23bd0
movq %rax, 0x30(%rsp)
cmpq $0x0, 0x30(%rsp)
jne 0x3205b
movq 0x48(%rsp), %rsi
leaq 0x18995a(%rip), %rdi    # 0x1bb9a1
movb $0x0, %al
callq 0x120a50
movl $0x0, 0x54(%rsp)
jmp 0x3216f
movl $0x0, 0x2c(%rsp)
movl 0x2c(%rsp), %eax
movl %eax, 0x14(%rsp)
movq 0x1fdbc6(%rip), %rdi    # 0x22fc38
callq 0x321c0
movl %eax, %ecx
movl 0x14(%rsp), %eax
cmpl %ecx, %eax
jge 0x320fe
movq 0x1fdbb0(%rip), %rdi    # 0x22fc38
movl 0x2c(%rsp), %esi
callq 0x32430
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rdi
callq 0x32460
cmpq $0x0, %rax
je 0x320b7
movq 0x20(%rsp), %rdi
callq 0x32460
movq %rax, 0x8(%rsp)
jmp 0x320c5
leaq 0x189544(%rip), %rax    # 0x1bb602
movq %rax, 0x8(%rsp)
jmp 0x320c5
movq 0x8(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x30(%rsp), %rdi
movl 0x2c(%rsp), %edx
addl $0x1, %edx
movq 0x18(%rsp), %rcx
leaq 0x1898dc(%rip), %rsi    # 0x1bb9c3
movb $0x0, %al
callq 0x23f00
movl 0x2c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x2c(%rsp)
jmp 0x32063
movq 0x30(%rsp), %rdi
callq 0x239a0
cmpl $0x0, 0x1fdaa5(%rip)    # 0x22fbb4
je 0x32167
movq 0x48(%rsp), %rsi
leaq 0x1898ad(%rip), %rdi    # 0x1bb9ca
movb $0x0, %al
callq 0x23090
leaq 0x38(%rsp), %rdi
callq 0x11bb90
leaq 0x189305(%rip), %rdi    # 0x1bb43a
movb $0x1, %al
callq 0x23090
movq 0x1fdaf5(%rip), %rdi    # 0x22fc38
callq 0x321c0
movl %eax, %esi
leaq 0x189300(%rip), %rdi    # 0x1bb451
movb $0x0, %al
callq 0x23090
movq 0x1f6e31(%rip), %rax    # 0x228f90
movq (%rax), %rdi
callq 0x23bc0
movl $0x1, 0x54(%rsp)
movl 0x54(%rsp), %eax
addq $0x58, %rsp
retq
nopl (%rax,%rax)
// File: tomfunkhouser[P]gaps/apps/scn2cam/../../pkgs/R3Shapes/R3Kdtree.cpp
// Function: gaps::R3Kdtree<Camera*>::FindAny(Camera*, double, double, int (*)(Camera*, Camera*, void*), void*) const
PtrType R3Kdtree<PtrType>::
FindAny(PtrType query_point, 
  RNScalar min_distance, RNScalar max_distance, 
  int (*IsCompatible)(PtrType, PtrType, void *), void *compatible_data) const
{
  // Check root
  if (!root) return NULL;

  // Use squared distances for efficiency
  if (max_distance < 0) return NULL;
  if (min_distance < 0) min_distance = 0;
  RNLength min_distance_squared = min_distance * min_distance;
  RNLength max_distance_squared = max_distance * max_distance;

  // Search nodes recursively
  return FindAny(root, bbox, 
    query_point, Position(query_point),
    min_distance_squared, max_distance_squared, 
    IsCompatible, compatible_data);
}

// Assembly:
subq $0x88, %rsp
movq %rdi, 0x78(%rsp)
movq %rsi, 0x70(%rsp)
movsd %xmm0, 0x68(%rsp)
movsd %xmm1, 0x60(%rsp)
movq %rdx, 0x58(%rsp)
movq %rcx, 0x50(%rsp)
movq 0x78(%rsp), %rax
movq %rax, 0x20(%rsp)
cmpq $0x0, 0x50(%rax)
jne 0x33899
movq $0x0, 0x80(%rsp)
jmp 0x33952
xorps %xmm0, %xmm0
ucomisd 0x60(%rsp), %xmm0
jbe 0x338b5
movq $0x0, 0x80(%rsp)
jmp 0x33952
xorps %xmm0, %xmm0
ucomisd 0x68(%rsp), %xmm0
jbe 0x338c9
xorps %xmm0, %xmm0
movsd %xmm0, 0x68(%rsp)
movq 0x20(%rsp), %rsi
movsd 0x68(%rsp), %xmm0
mulsd 0x68(%rsp), %xmm0
movsd %xmm0, 0x48(%rsp)
movsd 0x60(%rsp), %xmm0
mulsd 0x60(%rsp), %xmm0
movsd %xmm0, 0x40(%rsp)
movq 0x50(%rsi), %rax
movq %rax, 0x10(%rsp)
movq 0x70(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x70(%rsp), %rdx
leaq 0x28(%rsp), %rdi
callq 0x347a0
movq 0x10(%rsp), %rsi
movq 0x20(%rsp), %rdx
movq 0x18(%rsp), %rcx
movsd 0x48(%rsp), %xmm0
movsd 0x40(%rsp), %xmm1
movq 0x58(%rsp), %r9
movq 0x50(%rsp), %rax
leaq 0x28(%rsp), %r8
movq %rdx, %rdi
movq %rax, (%rsp)
callq 0x33b80
movq %rax, 0x80(%rsp)
movq 0x80(%rsp), %rax
addq $0x88, %rsp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
// File: tomfunkhouser[P]gaps/pkgs/R3Shapes/R3PointSet.cpp
// Function: gaps::R3PointSet::~R3PointSet()
R3PointSet::
~R3PointSet(void)
{
  // Delete OpenGL buffers
  if (vbo_position_buffer > 0) glDeleteBuffers(1, &vbo_position_buffer);
  if (vbo_normal_buffer > 0) glDeleteBuffers(1, &vbo_normal_buffer);
  if (vbo_rgb_color_buffer > 0) glDeleteBuffers(1, &vbo_rgb_color_buffer);
  if (vbo_pick_color_buffer > 0) glDeleteBuffers(1, &vbo_pick_color_buffer);
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x18(%rsp)
cmpl $0x0, 0x108(%rax)
jbe 0xdca7d
movq 0x18(%rsp), %rsi
movq 0x14c578(%rip), %rax    # 0x228fe0
movq (%rax), %rax
addq $0x108, %rsi            # imm = 0x108
movl $0x1, %edi
callq *%rax
jmp 0xdca7b
jmp 0xdca7d
movq 0x18(%rsp), %rax
cmpl $0x0, 0x10c(%rax)
jbe 0xdcaac
movq 0x18(%rsp), %rsi
movq 0x14c549(%rip), %rax    # 0x228fe0
movq (%rax), %rax
addq $0x10c, %rsi            # imm = 0x10C
movl $0x1, %edi
callq *%rax
jmp 0xdcaaa
jmp 0xdcaac
movq 0x18(%rsp), %rax
cmpl $0x0, 0x110(%rax)
jbe 0xdcadb
movq 0x18(%rsp), %rsi
movq 0x14c51a(%rip), %rax    # 0x228fe0
movq (%rax), %rax
addq $0x110, %rsi            # imm = 0x110
movl $0x1, %edi
callq *%rax
jmp 0xdcad9
jmp 0xdcadb
movq 0x18(%rsp), %rax
cmpl $0x0, 0x114(%rax)
jbe 0xdcb0a
movq 0x18(%rsp), %rsi
movq 0x14c4eb(%rip), %rax    # 0x228fe0
movq (%rax), %rax
addq $0x114, %rsi            # imm = 0x114
movl $0x1, %edi
callq *%rax
jmp 0xdcb08
jmp 0xdcb0a
movq 0x18(%rsp), %rdi
addq $0x118, %rdi            # imm = 0x118
callq 0x33500
movq 0x18(%rsp), %rdi
addq $0xf0, %rdi
callq 0xdf980
movq 0x18(%rsp), %rdi
addq $0xd8, %rdi
callq 0xdf980
movq 0x18(%rsp), %rdi
addq $0xc0, %rdi
callq 0xb09f0
movq 0x18(%rsp), %rdi
addq $0xa8, %rdi
callq 0xb09f0
movq 0x18(%rsp), %rdi
addq $0x90, %rdi
callq 0xdf980
movq 0x18(%rsp), %rdi
addq $0x78, %rdi
callq 0xdf9e0
movq 0x18(%rsp), %rax
addq $0x48, %rax
movq %rax, 0x8(%rsp)
addq $0x30, %rax
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rdi
addq $-0x18, %rdi
movq %rdi, (%rsp)
callq 0xdf980
movq 0x8(%rsp), %rcx
movq (%rsp), %rax
cmpq %rcx, %rax
movq %rax, 0x10(%rsp)
jne 0xdcb95
movq 0x18(%rsp), %rdi
addq $0x30, %rdi
callq 0xdfa40
movq 0x18(%rsp), %rdi
addq $0x18, %rdi
callq 0xdfa40
movq 0x18(%rsp), %rdi
callq 0xb0c50
addq $0x28, %rsp
retq
movq %rax, %rdi
callq 0x32eb0
nopl (%rax)