From xemacs-m  Wed Mar 19 17:44:55 1997
Received: from altair.xemacs.org (steve@xemacs.miranova.com [206.190.83.19])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id RAA29360
	for <xemacs-beta@xemacs.org>; Wed, 19 Mar 1997 17:44:53 -0600 (CST)
Received: (from steve@localhost)
	by altair.xemacs.org (8.8.5/8.8.5) id PAA18095;
	Wed, 19 Mar 1997 15:56:31 -0800
Mail-Copies-To: never
To: xemacs-beta@xemacs.org
Subject: In memory JPEG (was Re: Subwindows)
References: <12558.858809513@kocrsw12> 	<25066.858811919@rtp.ericsson.se> 	<m2ybbjwk36.fsf@altair.xemacs.org> <QQchpm15669.199703192336@crystal.WonderWorks.COM>
X-Url: http://www.miranova.com/%7Esteve/
X-Face: #!T9!#9s-3o8)*uHlX{Ug[xW7E7Wr!*L46-OxqMu\xz23v|R9q}lH?cRS{rCNe^'[`^sr5"
 f8*@r4ipO6Jl!:Ccq<xoV[Qz2u8<8-+Vwf2gzJ44lf_/y9OaQ`@#Q65{U4/TC)i2`~/M&QI$X>p:9I
 OSS'2{-)-4wBnVeg0S\O4Al@)uC[pD|+
X-Attribution: sb
From: Steven L Baur <steve@miranova.com>
In-Reply-To: Kyle Jones's message of Wed, 19 Mar 1997 18:36:33 -0500 (EST)
Mime-Version: 1.0 (generated by tm-edit 7.105)
Content-Type: text/plain; charset=US-ASCII
Date: 19 Mar 1997 15:56:26 -0800
Message-ID: <m2iv2niggl.fsf_-_@altair.xemacs.org>
Lines: 43
X-Mailer: Gnus v5.4.32/XEmacs 20.1(beta9)

Kyle Jones writes:

> Another bug, like the one Darrell Kindred fixed
> with pixmap backgrounds, that probably has a simple solution.

Speaking of trivial patches fixing long standing problems did anyone
else try the JPEG patch recently posted on comp.emacs.xemacs?  It
seems to work.

Index: src/glyphs-x.c
===================================================================
RCS file: /usr/local/xemacs/xemacs-20.0/src/glyphs-x.c,v
retrieving revision 1.6
diff -u -r1.6 glyphs-x.c
--- glyphs-x.c	1997/03/18 03:27:08	1.6
+++ glyphs-x.c	1997/03/19 23:35:57
@@ -1053,7 +1059,7 @@
 #include "jerror.h"
 
 /* The in-core jpeg code doesn't work, so I'm avoiding it for now.  -sb  */
-#define USE_TEMP_FILES_FOR_JPEG_IMAGES 1
+/*#define USE_TEMP_FILES_FOR_JPEG_IMAGES 1*/
 #define USE_TEMP_FILES_FOR_PNG_IMAGES 1
 
 static void
@@ -1185,6 +1191,12 @@
 METHODDEF void
 #endif
 our_skip_input_data (j_decompress_ptr cinfo, long num_bytes) {
+  struct jpeg_source_mgr *src = NULL;
+
+  src = (struct jpeg_source_mgr *) cinfo->src;
+
+  src->bytes_in_buffer -= num_bytes;
+  src->next_input_byte += num_bytes;
 }
 
 #if defined(JPEG_LIB_VERSION) && (JPEG_LIB_VERSION >= 61)


-- 
steve@miranova.com baur
Unsolicited commercial e-mail will be billed at $250/message.

