GithubHelp home page GithubHelp logo

cleasbycode / jzp Goto Github PK

View Code? Open in Web Editor NEW
0.0 0.0 0.0 1.85 MB

CLI tool to embed small files (e.g. "workflow.json") within a JPG image to create a tweetable JPG-ZIP polyglot file.

License: MIT License

C++ 100.00%
cplusplus image image-prompt jpg metadata prompt twitter zip json rar

jzp's Introduction

jzp

When posted on its platform, Twitter will remove the metadata from your image file.

jzp is a command-line tool used to embed small files (up to 10KB) into a JPG image,
that will not be removed by Twitter. Your embedded data file "travels" with the image.

For compatibility reasons, I would recommend using JPG images saved from Twitter for your cover image.

To maximise the amount of data you can embed, it is recommended to compress (ZIP/RAR) your data file.

Demo Image_a
{Original image source}

Your embedded file is stored within the ICC Profile of the JPG image.

Demo Image_b

Compile and run the program under Windows or Linux

Usage (Linux Example)

$ g++ jzp.cpp -O2 -s -o jzp
$
$ ./jzp

Usage: jzp <cover_image> <data_file>
       jzp --info

$ ./jzp image.jpg sdxl_workflow_json.rar

 Created output file: "jzp_img.jpg 9256 Bytes"
 You can now post this data-embedded image file on Twitter.

Extracting Your Embedded File(s)

To get access to and extract your data file for a ZIP or RAR embedded file with a Linux desktop,
just rename the .jpg file extension to .zip, then click the file icon to open & extract the ZIP/RAR contents.

For just a RAR file under Linux, you don't need to rename the file extension. From a Linux terminal enter the following command:

 $ unrar e jzp_img.jpg

For an embedded ZIP file under Windows, rename the .jpg file extension to .zip.
From a console type the following command:

 PS C:\Demo> Expand-Archive .\jzp_img.zip .

For a RAR file under Windows, you will need to use a program such as WinRar to extract your file from the image.

My other programs you may find useful:-

jzp's People

Contributors

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