// File: /workspace/github_cpp_makefile_star2_O1/ticky[P]ps2iconsys/src/ps2icon_to_obj.cpp
// Function: LoadPS2Icon()
PS2Icon* LoadPS2Icon()
{
	PS2Icon* ret = NULL;
	if(verbose_output)
		std::cout << " * Reading PS2Icon file \"" << ps2_input_file << "\"...\n";
	try {
		ret = new PS2Icon(ps2_input_file);
	} catch( std::exception e ) {
		std::cout << "File read error: \"" << ps2_input_file << "\"" << std::endl;
		exit(1);
	}
	if(verbose_output)
		std::cout << " **  Found geometry - " << ret->GetNVertices() << " vertices, " 
			<< ret->GetNShapes() << " shapes." << std::endl;
	if(ret->GetNFrames() > 1) {
		std::cout << " **  Found animation - " << ret->GetNFrames() << " frames." << std::endl;
	}
	if(verbose_output)
		std::cout << " *  done." << std::endl;
	return ret;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
cmpb $0x1, 0x65b4(%rip)      # 0xf270
jne 0x8d30
movq 0x6313(%rip), %rbx      # 0xefd8
leaq 0x1d19(%rip), %rsi      # 0xa9e5
movl $0x19, %edx
movq %rbx, %rdi
callq 0x21f0
movq 0x6578(%rip), %r14      # 0xf258
testq %r14, %r14
je 0x8d01
movq %r14, %rdi
callq 0x20c0
movq 0x62e4(%rip), %rdi      # 0xefd8
movq %r14, %rsi
movq %rax, %rdx
callq 0x21f0
jmp 0x8d18
movq (%rbx), %rax
movq -0x18(%rax), %rax
leaq (%rbx,%rax), %rdi
movl 0x20(%rbx,%rax), %esi
orl $0x1, %esi
callq 0x22f0
movq 0x62b9(%rip), %rdi      # 0xefd8
leaq 0x1cd9(%rip), %rsi      # 0xa9ff
movl $0x5, %edx
callq 0x21f0
movl $0x10068, %edi          # imm = 0x10068
callq 0x21c0
movq %rax, %rbx
movq 0x6514(%rip), %rsi      # 0xf258
movq %rax, %rdi
callq 0x5bd0
cmpb $0x0, 0x651d(%rip)      # 0xf270
je 0x8ded
movq 0x6278(%rip), %r14      # 0xefd8
leaq 0x1cb1(%rip), %rsi      # 0xaa18
movl $0x16, %edx
movq %r14, %rdi
callq 0x21f0
movq %rbx, %rdi
callq 0x6adc
movq %r14, %rdi
movl %eax, %esi
callq 0x2310
movq %rax, %r14
leaq 0x1c9f(%rip), %rsi      # 0xaa2f
movl $0xb, %edx
movq %rax, %rdi
callq 0x21f0
movq %rbx, %rdi
callq 0x6b16
movq %r14, %rdi
movl %eax, %esi
callq 0x2310
movq %rax, %r14
leaq 0x1c82(%rip), %rsi      # 0xaa3b
movl $0x8, %edx
movq %rax, %rdi
callq 0x21f0
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2190
movsbl %al, %esi
movq %r14, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x2120
movq %rbx, %rdi
callq 0x6b50
cmpl $0x2, %eax
jl 0x8e65
movq 0x61d7(%rip), %r14      # 0xefd8
leaq 0x1c3c(%rip), %rsi      # 0xaa44
movl $0x17, %edx
movq %r14, %rdi
callq 0x21f0
movq %rbx, %rdi
callq 0x6b50
movq %r14, %rdi
movl %eax, %esi
callq 0x2310
movq %rax, %r14
leaq 0x1c2b(%rip), %rsi      # 0xaa5c
movl $0x8, %edx
movq %rax, %rdi
callq 0x21f0
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2190
movsbl %al, %esi
movq %r14, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x2120
cmpb $0x1, 0x6404(%rip)      # 0xf270
jne 0x8eb0
movq 0x6163(%rip), %r14      # 0xefd8
leaq 0x1be9(%rip), %rsi      # 0xaa65
movl $0x9, %edx
movq %r14, %rdi
callq 0x21f0
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2190
movsbl %al, %esi
movq %r14, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x2120
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rdx, %r15
movq %rax, %r14
movl $0x10068, %esi          # imm = 0x10068
movq %rbx, %rdi
callq 0x21d0
jmp 0x8ed8
movq %rdx, %r15
movq %rax, %r14
cmpl $0x1, %r15d
jne 0x8f68
movq %r14, %rdi
callq 0x2220
movq 0x60df(%rip), %rax      # 0xefd0
addq $0x10, %rax
movq %rax, 0x8(%rsp)
movq %r14, %rdi
callq 0x20b0
movq 0x60cf(%rip), %rdi      # 0xefd8
leaq 0x1af5(%rip), %rsi      # 0xaa05
movl $0x12, %edx
callq 0x21f0
movq 0x6337(%rip), %rsi      # 0xf258
movq 0x60b0(%rip), %rdi      # 0xefd8
callq 0x21b0
movq %rax, %rbx
leaq 0x1adf(%rip), %rsi      # 0xaa16
movl $0x1, %edx
movq %rax, %rdi
callq 0x21f0
movq %rbx, %rdi
callq 0x20d0
movl $0x1, %edi
callq 0x2210
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x2380
callq 0x22e0
movq %r14, %rdi
callq 0x2330
movq %rax, %rdi
callq 0x7272