8000 Please add CRC32-MPEG2 · Issue #65 · alexgorbatchev/crc · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Please add CRC32-MPEG2 #65
Open
Open
@brandonros

Description

@brandonros
unsigned int crc32b(unsigned char *message, size_t l)
{
   size_t i, j;
   unsigned int crc, msb;

   crc = 0xFFFFFFFF;
   for(i = 0; i < l; i++) {
      // xor next byte to upper bits of crc
      crc ^= (((unsigned int)message[i])<<24);
      for (j = 0; j < 8; j++) {    // Do eight times.
            msb = crc>>31;
            crc <<= 1;
            crc ^= (0 - msb) & 0x04C11DB7;
      }
   }
   return crc;         // don't complement crc on output
}

https://stackoverflow.com/questions/54339800/how-to-modify-crc-32-to-crc-32-mpeg-2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0