Giter VIP home page Giter VIP logo

bmp2coe's Introduction

bmp2coe

GitHub license

bmp2coe is made for generating coefficient files for Xilinx Vivado from bitmap files.

Usage

ffmpeg -y -i input.png -pix_fmt {bgr24 | rgb444le} output.bmp
./bmp2coe.ps1 [-PixelFormat] {bgr24 | rgb444le}

The script will convert all .bmp files in the same folder. One of the following pixel formats must be specified (all formats use bottom-up row order and will append a padding pixel to each row if the image width is an odd number):

  • bgr24 as exported by FFmpeg, which uses compact BGR pixel layout. The output file will use 8-bit wordlength.

  • rgb565le as exported by FFmpeg, which uses 5R6G5B little-endian pixel layout. This may work for rgb555le (1A5R5G5B little-endian) as well. The output file will use 16-bit wordlength.

  • rgb444le as exported by FFmpeg, which uses 4A4R4G4B little-endian pixel layout. The output file will use 12-bit wordlength.

Note that FFmpeg will apply dithering to the image when operates bit depth reduction by default.

bmp2coe's People

Contributors

davidxuang avatar

Watchers

 avatar  avatar

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.