Giter Site home page Giter Site logo

001101 / mybiptools Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kartun83/mybiptools

0.0 2.0 0.0 1.48 MB

Utilities for making Amazfit BIP watch faces

License: GNU General Public License v3.0

Makefile 39.93% C++ 41.01% C 1.70% Python 0.57% QML 16.03% JavaScript 0.52% QMake 0.24%

mybiptools's Introduction

myBipTools

Utilities for making Amazfit BIP watch faces

Requrements: python3, imagemagick

Note for Windows users

Download imagemagick portable and extract magick.exe and colors.xml into script directory. Tested on windows10

Linux

Shold work out of box, in most distributions required software available via package manager. Tested on Linux mint 18.3 with default repositories. Should work with most Ubuntu family distributions.

font_convert.py

Tool for converting TTF/OTF fonts into PNG images. Allow to generate images for dights, and/or images for texts defined in file, one line per text entry

Usage examples

'./font_convert.py' --help

Get basic help on available commands

'./font_convert.py' -ttf thin.ttf --foreground=white -bg=bip_none -sz 25 -d delimeter --offset 62

Generate numbers 0-9 as png images using font thin.ttf, and generate images from lines of file delimeter (one line per image), starting with 62.png as image for 0.

'./font_convert.py' -ttf thin.ttf --foreground=white -bg=bip_none -sz 25 -d delimeter -sd -p prefix

Generate images only from file delimeter, without generating dights, prefixing generated filenames with text 'prefix', for example 'prefixJan.png', if file delimeter contains only single line with text 'Jan'

Colors Amazfit BIP supports limited colors, use this constants to be on a safe side. Actually RGB color could be used, for example ./font_convert.py' --foreground='#0000FF'. Tool would try to analyze supplied color and generate warnings if unsupported color is used.

  • black
  • blue
  • green
  • red
  • aqua, cyan
  • fuchsia, magenta
  • yellow
  • white
  • bip_none. Actual transparency for png: none. Not sure if BIP can handle this properly

qBipDesigner

Goal of this tool to provide realtime feedback and allow user to design watch faces without minimal efforts and maximum productivity. Currently it's proof of concept that this could be done mostly with pure QML\Javascript. At this time it could do:

  • Load JSON file
  • Locate images defined in JSON file
  • Respond to changes in JSON data in embedded editor bad info : currently it supports only background manipulation. It ignors all other properties.

Requires : QT5, build with QT 5.10

Cross compiling for Windows

  • Clone mxe(https://github.com/mxe/mxe)
  • Check that qt compiles with current mxe(http://mxe.cc/build-matrix.html)
  • If so, build gcc with make MXE_TARGETS='x86_64-w64-mingw32.shared' gcc -j4 JOBS=4
  • Build required modules make MXE_TARGETS='x86_64-w64-mingw32.shared' qtbase qtdeclarative qtgraphicaleffects qtimageformats qtmultimedia qtquickcontrols qtquickcontrols2 qtsystems qttools qttranslations qtwinextras -j4 JOBS=4 , or build all with make MXE_TARGETS='x86_64-w64-mingw32.shared' qt5 -j4 JOBS=4 ** Replace shared with static if you prefer static builds ** Adjust jobs count depending on your cpu
  • For shared builds to assemble runtime: ** copydlldeps.sh ** If deploying directly from qt add build step : --copy --infile '%{CurrentRun:Executable:FilePath}' --enforcedir '%{Qt:QT_INSTALL_PREFIX}/plugins/platforms' --enforcedir '%{Qt:QT_INSTALL_PREFIX}/qml/QtQuick/Controls.2' --destdir '%{CurrentRun:Executable:NativePath}/deploy' --srcdir '%{Qt:QT_INSTALL_PREFIX}' --recursivesrcdir

mybiptools's People

Contributors

kartun83 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.