04-27-2009
The compiler may have optimized it away. It sees 'hmm, this value never changes! Therefore I can assume it is a hardcoded zero' and does so. If you instead declare it as 'volatile int var1' then the compiler will not make such assumptions.
10 More Discussions You Might Find Interesting
1. Programming
Hello all,
I'm going to be using some of the date functions from time.h to do some time stamping. I will be getting a time and date from the header of a TIFF file. I will need to be able create a time for each time zone in the U.S. The source of the time stamp will be in GMT. What I'd like to do... (2 Replies)
Discussion started by: shldBcding
2 Replies
2. HP-UX
Hello,
J create a thread C with a JNI function via JAVA.
J have the following message (but not in each time):
Someone has an idea ?
Thank.
Unexpected Signal : 4 occurred at PC=0x78C103E0
Function=
Library=(N/A)
NOTE: We are unable to locate the function name... (0 Replies)
Discussion started by: AUBERT
0 Replies
3. Shell Programming and Scripting
Hello,
I am needing to create a variable and assign it a value based on the value of a previosly defined variable... I am using KSH..
Example:
VAR1=COMPUTER1
I need another variable like ${VAR1}_FLAG="Y", so it would actually be COMPUTER1_FLAG="Y".
I will be looping through many values in... (2 Replies)
Discussion started by: benefactr
2 Replies
4. Programming
hi all,
my requirement is to create a thread by calling another function.
i.e i dont call pthread_create directly from main, but by calling another function (createThd - below ), from main.
Example:
void *thread_function(void *arg) { /* thread function */
int i;
rc =... (3 Replies)
Discussion started by: wolwy_pete
3 Replies
5. UNIX for Advanced & Expert Users
I think I know the answer but I'll ask and see if someone with more expertise can share new light on this topic: Does Ksh have the capability to create new threads (not processes) and/or offer some multiplexing on named pipes?
Thanks for your assistance!
~sreyes27 (2 Replies)
Discussion started by: sreyes27
2 Replies
6. Programming
I try to initial a UDP client from threading, but it doesn't work? why?
These codes from the textbook
#define ECHOMAX 255 /* Longest string to echo */
#define TIMEOUT_SECS 2 /* Seconds between retransmits */
#define MAXTRIES 5 /* Tries before giving up */... (3 Replies)
Discussion started by: sehang
3 Replies
7. Post Here to Contact Site Administrators and Moderators
please tell me how can i post a new post. i am not getting any option to post a new question.
any suggestion is highly appreciated.
thanks,
Arpit (1 Reply)
Discussion started by: thearpit
1 Replies
8. UNIX for Advanced & Expert Users
Hello everyone,
I created a test program for pthread priority set. Here's the code, very simple, 60 lines only.
I've tried this prog on my Fedora 13(on vbox), and on my 6410 arm linux 2.6.36. Both the same result.
Both environments are using root privileges.
Can any body tells me why the... (15 Replies)
Discussion started by: ss1969
15 Replies
9. Forum Support Area for Unregistered Users & Account Problems
Hi, Scott, I am still meet a problem when I want to reply or create a new thread in "Shell Programming and Scripting" Forum, It reminds that:
To create new threads in this forum your post count must be 10 or greater.
You currently have 2 posts.
To my surprise, I posted a thread in "Shell... (4 Replies)
Discussion started by: weichanghe2000
4 Replies
10. Forum Support Area for Unregistered Users & Account Problems
Hi.
I registered, but when trying to post, I get ...
"Sorry, you do not have enough Bits to post a new thread"
Google & Forum search showed some hits, but no solution.
Please advide.
Thanks! (1 Reply)
Discussion started by: gehe
1 Replies
LEARN ABOUT V7
ppmtosixel
ppmtosixel(1) General Commands Manual ppmtosixel(1)
NAME
ppmtosixel - convert a portable pixmap into DEC sixel format
SYNOPSIS
ppmtosixel [-raw] [-margin] [ppmfile]
DESCRIPTION
Reads a portable pixmap as input. Produces sixel commands (SIX) as output. The output is formatted for color printing, e.g. for a DEC
LJ250 color inkjet printer.
If RGB values from the PPM file do not have maxval=100, the RGB values are rescaled. A printer control header and a color assignment table
begin the SIX file. Image data is written in a compressed format by default. A printer control footer ends the image file.
OPTIONS
-raw If specified, each pixel will be explicitly described in the image file. If -raw is not specified, output will default to com-
pressed format in which identical adjacent pixels are replaced by "repeat pixel" commands. A raw file is often an order of magni-
tude larger than a compressed file and prints much slower.
-margin
If -margin is not specified, the image will be start at the left margin (of the window, paper, or whatever). If -margin is speci-
fied, a 1.5 inch left margin will offset the image.
PRINTING
Generally, sixel files must reach the printer unfiltered. Use the lpr -x option or cat filename > /dev/tty0?.
BUGS
Upon rescaling, truncation of the least significant bits of RGB values may result in poor color conversion. If the original PPM maxval was
greater than 100, rescaling also reduces the image depth. While the actual RGB values from the ppm file are more or less retained, the
color palette of the LJ250 may not match the colors on your screen. This seems to be a printer limitation.
SEE ALSO
ppm(5)
AUTHOR
Copyright (C) 1991 by Rick Vinci.
26 April 1991 ppmtosixel(1)