// File: /workspace/github_cpp_makefile_star2_O3/olegk0[P]readAVI/ReadAVI.cpp
// Function: ReadAVI::read_avi_header()
int ReadAVI::read_avi_header()
{
#ifdef VERBOSE
    long offset = inFile.tellg();
#endif
    avi_header.TimeBetweenFrames = read_int();
    avi_header.MaximumDataRate = read_int();
    avi_header.PaddingGranularity = read_int();
    avi_header.Flags = read_int();
    avi_header.TotalNumberOfFrames = read_int();
    avi_header.NumberOfInitialFrames = read_int();
    avi_header.NumberOfStreams = read_int();
    avi_header.SuggestedBufferSize = read_int();
    avi_header.Width = read_int();
    avi_header.Height = read_int();
    avi_header.TimeScale = read_int();
    avi_header.DataRate = read_int();
    avi_header.StartTime = read_int();
    avi_header.DataLength = read_int();

    MSG_DBG(2, "         offset=0x%lx\n", offset);
    MSG_DBG(2, "             TimeBetweenFrames: %d\n", avi_header.TimeBetweenFrames);
    MSG_DBG(2, "               MaximumDataRate: %d\n", avi_header.MaximumDataRate);
    MSG_DBG(2, "            PaddingGranularity: %d\n", avi_header.PaddingGranularity);
    MSG_DBG(2, "                         Flags: %d\n", avi_header.Flags);
    MSG_DBG(2, "           TotalNumberOfFrames: %d\n", avi_header.TotalNumberOfFrames);
    MSG_DBG(2, "         NumberOfInitialFrames: %d\n", avi_header.NumberOfInitialFrames);
    MSG_DBG(2, "               NumberOfStreams: %d\n", avi_header.NumberOfStreams);
    MSG_DBG(2, "           SuggestedBufferSize: %d\n", avi_header.SuggestedBufferSize);
    MSG_DBG(2, "                         Width: %d\n", avi_header.Width);
    MSG_DBG(2, "                        Height: %d\n", avi_header.Height);
    MSG_DBG(2, "                     TimeScale: %d\n", avi_header.TimeScale);
    MSG_DBG(2, "                      DataRate: %d\n", avi_header.DataRate);
    MSG_DBG(2, "                     StartTime: %d\n", avi_header.StartTime);
    MSG_DBG(2, "                    DataLength: %d\n", avi_header.DataLength);

    return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x20(%rdi), %r15
movq %r15, %rdi
callq 0x23e0
movq %rax, %r14
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x228(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x22c(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x230(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x234(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x238(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x23c(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x240(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x244(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x248(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x24c(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x250(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x254(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x258(%rbx)
leaq 0x4(%rsp), %r12
movl $0x4, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x22b0
movl (%r12), %eax
movl %eax, 0x25c(%rbx)
movq 0x4651(%rip), %r15      # 0x7fb0
movq (%r15), %rdi
leaq 0x1add(%rip), %rsi      # 0x5446
movq %r14, %rdx
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x228(%rbx), %edx
leaq 0x18c8(%rip), %rsi      # 0x524b
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x22c(%rbx), %edx
leaq 0x18d5(%rip), %rsi      # 0x526f
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x230(%rbx), %edx
leaq 0x18e2(%rip), %rsi      # 0x5293
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x234(%rbx), %edx
leaq 0x18ef(%rip), %rsi      # 0x52b7
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x238(%rbx), %edx
leaq 0x18fc(%rip), %rsi      # 0x52db
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x23c(%rbx), %edx
leaq 0x1909(%rip), %rsi      # 0x52ff
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x240(%rbx), %edx
leaq 0x1916(%rip), %rsi      # 0x5323
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x244(%rbx), %edx
leaq 0x1923(%rip), %rsi      # 0x5347
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x248(%rbx), %edx
leaq 0x1930(%rip), %rsi      # 0x536b
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x24c(%rbx), %edx
leaq 0x193d(%rip), %rsi      # 0x538f
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x250(%rbx), %edx
leaq 0x194a(%rip), %rsi      # 0x53b3
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x254(%rbx), %edx
leaq 0x1957(%rip), %rsi      # 0x53d7
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x258(%rbx), %edx
leaq 0x1964(%rip), %rsi      # 0x53fb
xorl %eax, %eax
callq 0x2340
movq (%r15), %rdi
movl 0x25c(%rbx), %edx
leaq 0x1971(%rip), %rsi      # 0x541f
xorl %eax, %eax
callq 0x2340
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop