Coder Social home page Coder Social logo

nlzm's People

Contributors

nauful avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

nlzm's Issues

header should be 1byte

Header includes hist_bits and frame_bits. Both size is 2bytes. but both range is smaller than 32. And frame_bits is generated by Clamp(hist_bits - 2, 14U, 17U).
So header should be 1byte for hist_bits.

Compilation errors

The ERROR message

nl.cpp: In function ‘void RANS::init_cdf(int16 (&)[num_syms])’:
nl.cpp:255:19: error: ‘scale_bits’ was not declared in this scope
    cdf[i] = (i << scale_bits) / num_syms;
                   ^~~~~~~~~~
nl.cpp:255:19: note: suggested alternative: ‘scale_max’
    cdf[i] = (i << scale_bits) / num_syms;
                   ^~~~~~~~~~
                   scale_max
nl.cpp: In function ‘uint32 crc32_calc(const byte*, int64, uint64)’:
nl.cpp:3318:24: error: cast from ‘const byte*’ {aka ‘const unsigned char*’} to ‘byte’ {aka ‘unsigned char’} loses precision [-fpermissive]
  while (n && (byte(next) & 15)) {
                        ^

I removed init_cdf and replaced next with *next for it to work.

Also it would be nice if you didn't use windows only stuff like #include <intrin.h>.
There are possibly other windows only stuff.
I crosscompiled it to windows and the run it using wine in linux.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.