[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
put_code
From: |
m . degregorio |
Subject: |
put_code |
Date: |
Thu, 1 Nov 2012 12:30:08 +0100 |
User-agent: |
Internet Messaging Program (IMP) H3 (4.1.6) |
I am trying to automatically generate PPM P5 files.
In order to write the binary part of the files, I am using
put_code/1
It says that accepts non negative integer numbers. My aim is to
produce greyscale images so I need to write numbers that represent
the grey level. Of course, numbers go from 0 to 255.
That's the problem.
put_code(1)
up to
put_code(255)
work;
but
put_code(0)
does not.
I get
ERROR:Exception error(representation_error(character_code),put_code/1)
occurred while evaluating the query " put_code(0) ".
Please, give me a suggestion or an alternative solution for this problem.
Thanks in advance
----------------------------------------------------------------
Massimo De Gregorio
Research Scientist
Istituto di Cibernetica "Eduardo Caianiello" - CNR
Via Campi Flegrei 34
Comprensorio "A. Olivetti" - Ed. 70
80078 Pozzuoli (NA) - ITALIA
Tel. (+ 39) 0818675151
Fax: (+ 39) 0818675158
Skype: massimo.de.gregorio
E-mail: address@hidden
----------------------------------------------------------------
----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.
- put_code,
m . degregorio <=