Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Smacker video
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Technical details== ===File format (container)=== Smacker defines its own [[digital container format|container format]].<ref name=multimediawiki/> A Smacker file can contain a Smacker video track and up to seven audio tracks. Each audio track can have either one channel (mono) or two channels (stereo) with a [[Audio bit depth|bit depth]] of either 8-bit or 16-bit. The audio can either be uncompressed [[PCM]], compressed in the Smacker Audio format, or, in newer versions of Smacker, compressed in the [[Bink Audio]] format.<ref name=multimediawiki/> ===Video=== Smacker video supports 256 colors, but no transparency support.<ref name=multimediawiki/> While being a [[Palette (computing)|palette]]-based format, which is inherently limited to having not more than 256 colors in each frame, Smacker videos may still contain more colors in total due to "palette rotation", whereby the palette is updated on a per-frame basis.<ref name=multimediawiki/> This usually results in SMK files that look better if the source video has more than 256 colors. The compression rate depends on the content. The encoding of a video consisting of still or barely moving frames is after the first frame practically free.<ref name="multimediawiki" /> Frames with random colors might more than double the raw size.{{Citation needed|date=February 2011}} In Smacker video, a frame is split into 4Γ4 blocks in raster-scan order.<ref name=multimediawiki/> Each block can be coded in one of six coding modes: skip, fill, mono, and three full modes. Each mode can be signaled for multiple blocks in a [[run-length encoding]] scheme. In skip mode, the current block is copied from the previous frame in a [[conditional replenishment]] fashion. In fill mode, the current block is filled with a single color. In mono mode, the palette is locally reduced from 256 colors to two colors. Both colors are written to the bitstream and one bit per pixel is used to indicate which of the two colors a pixel should be.<ref name=multimediawiki/> The mono mode can be interpreted as [[vector quantization]], where a three-dimensional vector with the components red, green, and blue is [[color quantization|quantized]] using an adaptive codebook with two entries. There are three full modes, one was specified in version 2 of the Smacker format, while the other two were added in version 4.<ref name=multimediawiki/> In the original full mode, 16 colors are transmitted, one for each pixel, equivalent to raw uncompressed PCM. The two full modes added in version 4 use 4 and 8 colors in a block, respectively.<ref name=multimediawiki/> In the 4-color mode, the 4Γ4 block is split into four 2Γ2 blocks, each of which is filled with a solid color. In the 8-color mode, the 4Γ4 block is split into eight 1Γ2 blocks, each of which is filled with a solid color.<ref name=multimediawiki/> Further compression is achieved by [[entropy coding]] using [[Huffman coding]] of the various bitstream elements that result from the process above.<ref name=multimediawiki/> There are four separate Huffman tables, each with 16-bit entries: one for mode decision, run-length, and fill color in fill color mode, one for the color indices in mono mode, one for the bitmap in mono mode, and one for all data in the full mode. Each table is adaptive and transmitted once per file in the header. The Huffman tables in the header are themselves compressed: the 16 bit values in the leaves of the code tree are split into a high byte and a low byte. Each byte is compressed using a Huffman table that is also contained in the header.<ref name=multimediawiki/> ===Audio=== Smacker audio is one of the audio formats that can be used in the Smacker container. For compression, [[Differential pulse code modulation]] (DPCM) is used. The difference between two successive samples is compressed using [[Huffman coding]]. The Huffman tables are adapted once per audio frame.<ref name=multimediawiki/>
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)