Giter Site home page Giter Site logo

asciicam's Introduction

What is ASCIICam?

ASCIICam is a Java-made application that processes individual frames from a computer camera in order to produce an ASCII symbol video filter. This is done by creating sub-sections/images for each frame, calculating the average RGB values of them, and individually painting the corresponding symbol onto a single cell in a (currently) 64x48 grid using JFrame/JPanel.

Specifics.

  • Developed on Intellij w/ Maven build.
  • Uses JavaCV for capturing frames and converting them to buffered images.
  • Uses Swing, AWT, JFrame and JPanel for displaying ASCII symbols.
  • Current ASCII scale (from black to white, starting with a space(" ")): " _.,--=+:;cba!?0123456789$W#@".

Structure:

  • src/main/java/org/example/Main.java: Entry point of program; is also responsible for starting camera, grabbing frames, creating sub-images of said frames, calculating RGB averages, and passing RGB values into array (which is passed to customJPanel in constructor).
  • src/main/java/org/example/customJPanel.java: Class that extends abstract JPanel class; responsible for parsing RGB values from array and displaying appropriate ASCII symbol, per cell, onto JPanel stored in JFrame.

Code Flow Visualizer:

  • Main.java -> customJPanel.java

Releases:

  • v1.0.0 - Contains all necessary code to capture camera frames and display them using an "ASCII Filter"; ultimately producing a video filter.
  • v1.0.1 - Doubled resolution for finer images. Added more detailed comments in both Main.java and customJPaenl.java. Fixed symbol duplicate.

How to run locally.

COMING SOON

asciicam's People

Contributors

dfbdev avatar

Watchers

 avatar

asciicam's Issues

Adaptive resolution.

Should look into the stability of resolution across different devices. If ASCII image resolutions are inconsistent, then the program should dynamically calculate ASCII image resolution appropriately based on the device's image dimensions.

ASCII Scale symbol duplication.

There is currently a dash("-") duplication in the current ASCII scale that is used in the customJPanel class; there should be only one dash("-") symbol but there are 2.

Should replace symbol with a tilde ("~") or another appropriate ASCII symbol.

Resolution improvement.

Should look to improve the resolution of both the sub-image capturing and symbol painting. The current resolution for both stands at 64(width)x48(height); which leaves the final picture less-detailed than what's desired.

Also should look into creating a more adaptive frame-capturing system (in case the native captured-image resolution tends to change on different devices).

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.