Results 1 to 11 of 11

Thread: Stand-alone BCJ2?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Member
    Join Date
    May 2012
    Location
    United States
    Posts
    331
    Thanks
    191
    Thanked 55 Times in 39 Posts

    Stand-alone BCJ2?

    Hey guys,

    Has anyone made a simple, stand-alone BCJ2 filter executable? Something with a simple syntax like "bcj2.exe c/d input output"?

    Using 7z.exe+7z.dll/7za.exe is ok but it is a very large executable and is unnecessarily large when all I want to use is just BCJ2 filter.

    Thanks!

  2. #2
    Member
    Join Date
    May 2008
    Location
    Germany
    Posts
    412
    Thanks
    38
    Thanked 64 Times in 38 Posts
    may be this could help:
    https://github.com/quarkslab/linksys.../lzma/C/Bcj2.c

    by the way - a minimal 7za with only one compression-codec/variant would be a very interesting project

    best regards

  3. #3
    Programmer Bulat Ziganshin's Avatar
    Join Date
    Mar 2007
    Location
    Uzbekistan
    Posts
    4,552
    Thanks
    767
    Thanked 684 Times in 370 Posts
    BCJ2 has 4 output streams, so you need some way to interleave them. you may use 7z.exe for this purpose with the following switch: -m0=BCJ2

  4. #4
    Member
    Join Date
    May 2012
    Location
    United States
    Posts
    331
    Thanks
    191
    Thanked 55 Times in 39 Posts
    Quote Originally Posted by Bulat Ziganshin View Post
    BCJ2 has 4 output streams, so you need some way to interleave them. you may use 7z.exe for this purpose with the following switch: -m0=BCJ2
    Yes but I also need 7z.dll to use the BCJ2...Which then comes to 1MB HDD space just for BCJ2 filter...

    In the LZMA SDK there is a 7zr.exe file that can do BCJ2 and is not dependent on 7z.dll but that is 327KB...Again, that seems ridiculously large when a simple e8e9 filter is 5.5KB....I know, BCJ2 is more complex but I hardly think it needs 300KB...

    In the LZMA SDK, there are 2 files (bcj2.c and bcj2.h). Maybe those can be used to compile an simple EXE?

    I've attached the 2 aforementioned files. Could someone perhaps compile them (if it's possible)? I think others would find use in this as well.
    Attached Files Attached Files

  5. #5
    Programmer Bulat Ziganshin's Avatar
    Join Date
    Mar 2007
    Location
    Uzbekistan
    Posts
    4,552
    Thanks
    767
    Thanked 684 Times in 370 Posts
    comp1, they produce 4 output streams. so you need machinery to combine these streams together. also they use arithmetic coding which may employ other 7-zip source files? also lzma SDK contains only Bcj2_Decode(), encoder is C++ only

    may be you can use dispack instead? usually it beats bcj2 and it's 100 kb compiled
    Last edited by Bulat Ziganshin; 9th May 2014 at 14:23.

  6. #6
    Member
    Join Date
    May 2012
    Location
    United States
    Posts
    331
    Thanks
    191
    Thanked 55 Times in 39 Posts
    Quote Originally Posted by Bulat Ziganshin View Post
    comp1, they produce 4 output streams. so you need machinery to combine these streams together. also they use arithemtic codiing which may employ other 7-zip source files
    Ahhh I see...Now I understand what you're saying.

    EDIT: So just to double-check that I am understanding correctly. It is not possible to make an EXE that is only for the BCJ2 filter using all of the source files in the LZMA SDK?
    Last edited by comp1; 9th May 2014 at 15:49.

  7. #7
    Member
    Join Date
    Oct 2013
    Location
    Filling a much-needed gap in the literature
    Posts
    350
    Thanks
    177
    Thanked 49 Times in 35 Posts
    Bulat,

    Can you point me to dispack's home? I found a version 1.0, which looks interesting, but I don't know if that's what I should be looking at.

  8. #8
    Programmer Bulat Ziganshin's Avatar
    Join Date
    Mar 2007
    Location
    Uzbekistan
    Posts
    4,552
    Thanks
    767
    Thanked 684 Times in 370 Posts
    http://fgiesen.wordpress.com/2011/01...n-in-kkrunchy/ (paper)
    http://www.farbrausch.com/~fg/code/disfilter/ (source code)
    http://freearc.org/download/testing/dispack.exe (my compilation)
    http://encode.su/threads/557-disasm-...table-s-filter (my topic here)

    It is not possible to make an EXE that is only for the BCJ2 filter using all of the source files in the LZMA SDK?
    yes, i see in LZMA sdk only decoder

  9. Thanks:

    Paul W. (10th May 2014)

  10. #9
    Member
    Join Date
    May 2012
    Location
    United States
    Posts
    331
    Thanks
    191
    Thanked 55 Times in 39 Posts
    Quote Originally Posted by Bulat Ziganshin View Post
    yes, i see in LZMA sdk only decoder
    Bulat, if I could ask you one more question then. Could you make an EXE of the decoder using the source for me? The encoder being large (7z.exe+7z.dll or 7zr.exe) is not a big deal--the size of the BCJ2 decoder is most important.

    Could you or anybody make a 32-bit BCJ2 executable decoder with the source files in the LZMA SDK?

  11. #10
    Member
    Join Date
    May 2012
    Location
    United States
    Posts
    331
    Thanks
    191
    Thanked 55 Times in 39 Posts
    What a shame... thanks.

  12. #11
    Programmer Bulat Ziganshin's Avatar
    Join Date
    Mar 2007
    Location
    Uzbekistan
    Posts
    4,552
    Thanks
    767
    Thanked 684 Times in 370 Posts
    once again - it needs 4 input streams. their interleaving is defined inside 7-zip archiver code, so you need to compile entire 7z decompresor from lzma sdk sources

Similar Threads

  1. bcj2 ?
    By maorosh in forum Data Compression
    Replies: 9
    Last Post: 13th December 2009, 03:10
  2. Stand alone pcm dat preprocessor/filter
    By SvenBent in forum Data Compression
    Replies: 5
    Last Post: 15th May 2008, 15:36

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •