Go Back   FileForums > Game Backup > PC Games > PC Games - CD/DVD Conversions > Conversion Tutorials

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 17-02-2023, 09:34
Masquerade Masquerade is offline
Registered User
 
Join Date: Jan 2020
Location: Monte d'Or
Posts: 1,218
Thanks: 294
Thanked 1,407 Times in 637 Posts
Masquerade is on a distinguished road
Bink Video
  • XTool plugin adding support for Bink Video compression.
  • This plugin uses Bink Pack library by ProFrager.
  • Thanks to Razor12911 for the little help.
Advantages of using this plugin versus vanilla Bink Pack
  • Multithreading support.
  • No CRC check fail since XTool will patch the videos as they are unpacked.
  • Incompatible Bink 2 videos (KB2n) are automatically ignored.
Special Notes
  • For Bink 2 videos, you may need to make use of the --diff=* parameter as some patches between CRC imperfect videos to the original state can be larger than XTool's default threshold for patches.
  • You may need to use a large chunk size to ensure all videos are processed. See example below.
Example Usage
  • Extract the attached archive to the XTool folder and use -mbik or -mbk2 depending on your data set.
Test
  • Test on the videos from Assassin's Creed 2 (27x Bink 1 videos).
    Code:
    xtool precomp -mbik "AC2Videos\"
    XTool is created by Razor12911
    
    Streams: 13/13
    Time: 00:00:09 (00:00:01)
    Memory: 148 MB (148 MB)
    
    Results: 937 MB >> 928 MB
    Code:
    xtool precomp -c128mb -mbik "AC2Videos\"
    XTool is created by Razor12911
    
    Streams: 26/26
    Time: 00:02:12 (00:00:04)
    Memory: 391 MB (391 MB)
    
    Results: 937 MB >> 776 MB
    Code:
    xtool precomp -c256mb -mbik "AC2Videos\"
    XTool is created by Razor12911
    
    Streams: 27/27
    Time: 00:02:25 (00:00:06)
    Memory: 677 MB (677 MB)
    
    Results: 937 MB >> 725 MB
  • Test on 05_DAM folder from Shadow Warrior 3 Defintive Edition (6x Bink 2 videos).
    Code:
    xtool precomp -c256mb -mbk2 "SW3\Content\Movies\Cutscenes\05_DAM"
    XTool is created by Razor12911
    
    Streams: 6/6
    Time: 00:01:06 (00:00:03)
    Memory: 406 MB (406 MB)
    
    Results: 214 MB >> 187 MB
Attached Files
File Type: 7z XTool_Bink.7z (199.8 KB, 135 views)
File Type: 7z XTool_Bink_STDIO.7z (256.1 KB, 120 views)

Last edited by Masquerade; 06-03-2023 at 01:34.
Reply With Quote
The Following 10 Users Say Thank You to Masquerade For This Useful Post:
Cesar82 (17-02-2023), dixen (17-02-2023), Gehrman (18-02-2023), hdneo (17-02-2023), KaktoR (17-02-2023), kj911 (17-02-2023), L0v3craft (14-03-2023), Razor12911 (17-02-2023), ScOOt3r (14-05-2023), shazzla (17-02-2023)
Sponsored Links
  #2  
Old 17-02-2023, 19:36
Cesar82's Avatar
Cesar82 Cesar82 is offline
Registered User
 
Join Date: May 2011
Location: Brazil
Posts: 1,077
Thanks: 1,828
Thanked 2,311 Times in 789 Posts
Cesar82 is on a distinguished road
Quote:
Originally Posted by Masquerade View Post
For Bink 2 videos, you may need to make use of the --diff=* parameter as some patches between CRC imperfect videos to the original state can be larger than XTool's default threshold for patches.

For me if I use --diff=* in arc.ini it doesn't work, return:
ERROR: write error (disk full?) in compression algorithm xtool:c256mb:mbk2
Code:
Arc.ini

--cache=0
[External compressor:xtool]
header    = 0
default   = -c64mb -t100p
packcmd   = "{compressor}.exe" precomp { -option} --diff=* - - <stdin> <stdout>
unpackcmd = "{compressor}.exe" decode -t100p - - <stdin> <stdout>

pack.bat
arc.exe a -ep1 -dses --dirs -s; -lc- -di -i2 -r -w.\temp -m"xtool:c256mb:mbk2" data.arc "pack\*"
I also tested using it directly from the command line after removing --diff=* from arc.ini:
xtool:c256mb:mbk2:-diff=*
xtool:c256mb:mbk2:df*

Code:
Arc.ini

--cache=0
[External compressor:xtool]
header    = 0
default   = -c64mb -t100p
packcmd   = "{compressor}.exe" precomp { -option} - - <stdin> <stdout>
unpackcmd = "{compressor}.exe" decode -t100p - - <stdin> <stdout>

pack.bat
arc.exe a -ep1 -dses --dirs -s; -lc- -di -i2 -r -w.\temp -m"xtool:c256mb:mbk2:df*" data.arc "pack\*"
or
arc.exe a -ep1 -dses --dirs -s; -lc- -di -i2 -r -w.\temp -m"xtool:c256mb:mbk2:-diff=*" data.arc "pack\*"
If I don't use --diff=* it compresses normally.
Code:
FreeArc 0.67 (March 15 2014) using additional options: --cache=0
Creating archive: data.arc using xtool:c256mb:mbk2
Memory for compression 0b, decompression 0b, cache 0b
Compressing 5 files, 336,582,396 bytes
  Compressing health_screen.bk2
  Compressing ms_logo.bk2
  Compressing ps_studios_long_strawberry_4k30_006.bk2
  Compressing lt_outro_1080p.bk2
  Compressing lt_intro_1080p.bk2
Compressed 5 files, 336,582,396 => 291,316,936 bytes. Ratio 86.55%
Compression time: cpu 0.20 sec/real 29.95 sec = 1%. Speed 11.24 mB/s
All OK
Am I doing something wrong?
Reply With Quote
  #3  
Old 17-02-2023, 23:48
Masquerade Masquerade is offline
Registered User
 
Join Date: Jan 2020
Location: Monte d'Or
Posts: 1,218
Thanks: 294
Thanked 1,407 Times in 637 Posts
Masquerade is on a distinguished road
Quote:
Originally Posted by Cesar82 View Post
Am I doing something wrong?
The --diff parameter in XTool sets a max size in bytes or percentage size of the stream in order for XTool to accept the stream.

The * character is just a placeholder (a wildcard effectively meaning anything/everything). My explanation meant you'd need to change this to an integer.

By default, XTool will not accept a stream if the generated XDelta patch is greater in size than 5% of the stream, but using --diff= allows you to increase this threshold.

You can use --diff=20p to set the max patch size to be less than or equal to 20% of the stream size for XTool to accept the stream. You can also use an integer to specify a max patch size in bytes (e.g. --diff=50000).
Reply With Quote
The Following User Says Thank You to Masquerade For This Useful Post:
Cesar82 (18-02-2023)
  #4  
Old 11-03-2023, 12:46
exorc exorc is offline
Registered User
 
Join Date: Jan 2010
Location: Spain
Posts: 75
Thanks: 78
Thanked 6 Times in 6 Posts
exorc is on a distinguished road
Quote:
Originally Posted by Masquerade View Post
Bink Video
  • XTool plugin adding support for Bink Video compression.
  • This plugin uses Bink Pack library by ProFrager.
  • Thanks to Razor12911 for the little help.
Advantages of using this plugin versus vanilla Bink Pack
  • Multithreading support.
  • No CRC check fail since XTool will patch the videos as they are unpacked.
  • Incompatible Bink 2 videos (KB2n) are automatically ignored.
Special Notes
  • For Bink 2 videos, you may need to make use of the --diff=* parameter as some patches between CRC imperfect videos to the original state can be larger than XTool's default threshold for patches.
  • You may need to use a large chunk size to ensure all videos are processed. See example below.
Example Usage
  • Extract the attached archive to the XTool folder and use -mbik or -mbk2 depending on your data set.
Test
  • Test on the videos from Assassin's Creed 2 (27x Bink 1 videos).
    Code:
    xtool precomp -mbik "AC2Videos\"
    XTool is created by Razor12911
    
    Streams: 13/13
    Time: 00:00:09 (00:00:01)
    Memory: 148 MB (148 MB)
    
    Results: 937 MB >> 928 MB
    Code:
    xtool precomp -c128mb -mbik "AC2Videos\"
    XTool is created by Razor12911
    
    Streams: 26/26
    Time: 00:02:12 (00:00:04)
    Memory: 391 MB (391 MB)
    
    Results: 937 MB >> 776 MB
    Code:
    xtool precomp -c256mb -mbik "AC2Videos\"
    XTool is created by Razor12911
    
    Streams: 27/27
    Time: 00:02:25 (00:00:06)
    Memory: 677 MB (677 MB)
    
    Results: 937 MB >> 725 MB
  • Test on 05_DAM folder from Shadow Warrior 3 Defintive Edition (6x Bink 2 videos).
    Code:
    xtool precomp -c256mb -mbk2 "SW3\Content\Movies\Cutscenes\05_DAM"
    XTool is created by Razor12911
    
    Streams: 6/6
    Time: 00:01:06 (00:00:03)
    Memory: 406 MB (406 MB)
    
    Results: 214 MB >> 187 MB
How to use with DiskSpan GUI?
Reply With Quote
  #5  
Old 17-06-2023, 08:33
kj911 kj911 is offline
Registered User
 
Join Date: Apr 2010
Location: world
Posts: 233
Thanks: 158
Thanked 90 Times in 63 Posts
kj911 is on a distinguished road
Xtool 0.71 dont compress Bink video

Quote:
Originally Posted by Masquerade View Post
Bink Video
  • Extract the attached archive to the XTool folder and use -mbik or -mbk2 depending on your data set.
Whats wrong or am i lame?? (From testing. See two attached pictures.)

Directly use Binkpack.exe or Freearc usaged whole Bink*.exe file and or CLS-based (de)compressors its works in (de)compress in vice versa... Packed 3.07GB huge BIK file correctly to 2.4GB size with Binkpack.
Use Xtool 0.71 directly or Arc with configurations, don't compress smaller.
Attached Files
File Type: rar screenz.rar (583.9 KB, 16 views)
Reply With Quote
  #6  
Old 09-09-2023, 08:31
KaktoR's Avatar
KaktoR KaktoR is offline
Lame User
 
Join Date: Jan 2012
Location: From outer space
Posts: 4,705
Thanks: 1,106
Thanked 7,358 Times in 2,849 Posts
KaktoR is on a distinguished road
Quote:
Originally Posted by Masquerade View Post
Bink Video
  • XTool plugin adding support for Bink Video compression.
  • This plugin uses Bink Pack library by ProFrager.
  • Thanks to Razor12911 for the little help.
Advantages of using this plugin versus vanilla Bink Pack
  • Multithreading support.
  • No CRC check fail since XTool will patch the videos as they are unpacked.
  • Incompatible Bink 2 videos (KB2n) are automatically ignored.
Special Notes
  • For Bink 2 videos, you may need to make use of the --diff=* parameter as some patches between CRC imperfect videos to the original state can be larger than XTool's default threshold for patches.
  • You may need to use a large chunk size to ensure all videos are processed. See example below.
Example Usage
  • Extract the attached archive to the XTool folder and use -mbik or -mbk2 depending on your data set.
Updated plugin.

Basically the 'MessageBoxA' was patched out and replaced with some other function from User32.dll. On some bink2 inputs you had encountered some error messages like 'MotionData_warn' or 'err'. I have included two samples for which it is the case. You shouldn't receive error messages anymore with this patched plugin. Inputs which would give these types of errors are just ignored but processed still, but not compressed with binkpack.

Thanks to masquerade and Razor12911.
Attached Files
File Type: 7z XTool_Bink_STDIO_Patched.7z (4.56 MB, 138 views)
__________________
Haters gonna hate
Reply With Quote
The Following 8 Users Say Thank You to KaktoR For This Useful Post:
Abbat (26-01-2024), Gehrman (12-03-2024), kj911 (10-09-2023), L0v3craft (11-09-2023), Lord.Freddy (09-09-2023), murphy78 (15-09-2023), shazzla (09-09-2023), Wanterlude (10-09-2023)
  #7  
Old 06-03-2023, 01:34
Masquerade Masquerade is offline
Registered User
 
Join Date: Jan 2020
Location: Monte d'Or
Posts: 1,218
Thanks: 294
Thanked 1,407 Times in 637 Posts
Masquerade is on a distinguished road
Plugin Update

Added STDIN/STDOUT support for Bink Video plugin (thanks to Gehrman for idea).

Thanks to 78372 for cls wrapper.

Usage has not changed, but its significantly faster.
Reply With Quote
The Following 3 Users Say Thank You to Masquerade For This Useful Post:
Gehrman (06-03-2023), KaktoR (06-03-2023), L0v3craft (14-03-2023)
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
XTool 2020 (Main Project) Razor12911 Conversion Tutorials 714 19-07-2026 03:11
XTool - Successor of ZTool Razor12911 Conversion Tutorials 584 22-04-2023 18:16
[Dev]XTool Razor12911 Conversion Tutorials 180 23-10-2020 06:26
XTool 2019 (Plugins) Razor12911 Conversion Tutorials 50 16-05-2020 06:14



All times are GMT -7. The time now is 10:04.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
FileForums @ https://fileforums.com