LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 09-29-2013, 09:35 AM   #1
Xeratul
Senior Member
 
Registered: Jun 2006
Location: UNIX
Distribution: FreeBSD
Posts: 2,657

Rep: Reputation: 255Reputation: 255Reputation: 255
C MInimalist alternative to caca?


Hello,

Into a simple code, I would like to convert a png to a ascii file (monochrome).

There is tthat which is great.
Code:
caca-utils - text mode graphics utilities
libcaca-dev - development files for libcaca
libcaca0 - colour ASCII art library
But for reasons of portability, I would like to
have an embedded solution (wihtout aditional libs)
that would convert the png to ascii.

In this sense, a minimalist solution would be ideal, so that with a minimal of dependencies, it could be added to the c program.

For example of minimal include for basic use:
Code:
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <string.h>
#include <limits.h>
#include <errno.h>
#include <dirent.h>
#include <unistd.h>

Looking forward to reading your help, hints....
thanks a lot
 
Old 09-29-2013, 11:55 AM   #2
PTrenholme
Senior Member
 
Registered: Dec 2004
Location: Olympia, WA, USA
Distribution: Fedora, (K)Ubuntu
Posts: 4,187

Rep: Reputation: 354Reputation: 354Reputation: 354Reputation: 354
Have you looked at the libcaca source code? You might be able to base your "minimalist solution" on that.
 
Old 09-30-2013, 02:17 AM   #3
Xeratul
Senior Member
 
Registered: Jun 2006
Location: UNIX
Distribution: FreeBSD
Posts: 2,657

Original Poster
Rep: Reputation: 255Reputation: 255Reputation: 255
Quote:
Originally Posted by PTrenholme View Post
Have you looked at the libcaca source code? You might be able to base your "minimalist solution" on that.
I have looked and looking still. I remember that there was in a past sthg called "aa" alternative.

greetings
 
Old 09-30-2013, 02:43 AM   #4
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
"aa" alternative - aalib:
http://aa-project.sourceforge.net/aalib/
 
Old 09-30-2013, 09:56 AM   #5
Pap
Member
 
Registered: May 2011
Distribution: Salix 14.1 GNU/Linux, 64-bit
Posts: 70

Rep: Reputation: 29
I believe aalib is what you are looking for, as other people already mentioned. It is probably already installed in your system, as many useful applications require it, such as gimp, VLC media player, or gstreamer.
 
Old 10-01-2013, 02:48 AM   #6
Xeratul
Senior Member
 
Registered: Jun 2006
Location: UNIX
Distribution: FreeBSD
Posts: 2,657

Original Poster
Rep: Reputation: 255Reputation: 255Reputation: 255
Quote:
Originally Posted by Pap View Post
I believe aalib is what you are looking for, as other people already mentioned. It is probably already installed in your system, as many useful applications require it, such as gimp, VLC media player, or gstreamer.
nope

~$ dpkg -l | grep aalib

Proud of it...
look this configuration ultra light and very fast using tinywm mostly
http://pastebin.com/raw.php?i=y0a7AvJ6

Last edited by Xeratul; 10-01-2013 at 02:51 AM.
 
Old 10-01-2013, 07:19 AM   #7
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
Quote:
Originally Posted by Xeratul View Post
nope

~$ dpkg -l | grep aalib
On Debian (and I think derivatives) the package is called libaa1.
Which by the way was already known to you: http://www.linuxquestions.org/questi...aa-4175478238/
 
Old 10-01-2013, 09:49 AM   #8
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,659
Blog Entries: 4

Rep: Reputation: 3940Reputation: 3940Reputation: 3940Reputation: 3940Reputation: 3940Reputation: 3940Reputation: 3940Reputation: 3940Reputation: 3940Reputation: 3940Reputation: 3940
"caca occurs . . ."
 
Old 10-01-2013, 12:07 PM   #9
Xeratul
Senior Member
 
Registered: Jun 2006
Location: UNIX
Distribution: FreeBSD
Posts: 2,657

Original Poster
Rep: Reputation: 255Reputation: 255Reputation: 255
aa (aka aalib) never on my machine...


But I will look into aa.c ...
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
minimalist slackware piotrdk Slackware 28 06-18-2011 09:54 AM
console emulator using caca output? daweefolk Linux - Games 0 06-10-2010 11:14 PM
Minimalist kernel deardron Linux - Kernel 5 03-30-2007 02:03 PM
Which minimalist distro? k2skier Linux - Distributions 7 08-12-2005 04:42 AM
Minimalist/Perfectionist Nasty Linux - Newbie 21 10-10-2003 11:08 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 01:22 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration