Import Geant4 6.1.0 source tree
This commit is contained in:
@@ -20,6 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4HepRep.hh,v 1.16 2003/12/11 21:55:54 duns Exp $
|
||||
// GEANT4 tag $Name: geant4-06-00-patch-01 $
|
||||
//
|
||||
|
||||
/**
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4HepRepFile.hh,v 1.7 2003/07/12 19:48:15 duns Exp $
|
||||
// GEANT4 tag $Name: geant4-06-00 $
|
||||
// GEANT4 tag $Name: geant4-06-00-patch-01 $
|
||||
//
|
||||
//
|
||||
// John Allison 5th April 2001
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4HepRepFileSceneHandler.hh,v 1.14 2003/11/13 01:11:41 perl Exp $
|
||||
// GEANT4 tag $Name: geant4-06-00 $
|
||||
// GEANT4 tag $Name: geant4-06-00-patch-01 $
|
||||
//
|
||||
//
|
||||
// Joseph Perl 27th January 2002
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4HepRepFileViewer.hh,v 1.8 2003/07/12 19:48:15 duns Exp $
|
||||
// GEANT4 tag $Name: geant4-06-00 $
|
||||
// GEANT4 tag $Name: geant4-06-00-patch-01 $
|
||||
//
|
||||
//
|
||||
// John Allison 5th April 2001
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4HepRepMessenger.hh,v 1.3 2003/12/11 21:55:54 duns Exp $
|
||||
// GEANT4 tag $Name: geant4-06-00-patch-01 $
|
||||
//
|
||||
//
|
||||
#ifndef G4HepRepMessenger_HH
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4HepRepSceneHandler.hh,v 1.30 2003/12/11 21:55:55 duns Exp $
|
||||
// GEANT4 tag $Name: geant4-06-00-patch-01 $
|
||||
//
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4HepRepViewer.hh,v 1.16 2003/12/11 21:55:55 duns Exp $
|
||||
// GEANT4 tag $Name: geant4-06-00-patch-01 $
|
||||
//
|
||||
|
||||
/**
|
||||
|
||||
@@ -28,7 +28,7 @@ public:
|
||||
* Returns the associated HepRep to this object.
|
||||
*
|
||||
*/
|
||||
virtual HepRep getHepRep() = 0;
|
||||
virtual HepRep & getHepRep() = 0;
|
||||
}; // class
|
||||
} // namespace HEPREP
|
||||
#endif /* ifndef HEPREP_HASHEPREP_H */
|
||||
|
||||
@@ -5,16 +5,23 @@ G4HepRepFileSceneHandler.hh
|
||||
G4HepRepFileViewer.hh
|
||||
ref/HepRepXMLWriter.hh
|
||||
|
||||
and heprep2 files:
|
||||
|
||||
G4HepRep.hh
|
||||
G4HepRepSceneHandler.hh
|
||||
G4HepRepMessenger.hh
|
||||
G4HepRepViewer.hh
|
||||
|
||||
and the zlib headers
|
||||
|
||||
zlib/*.h
|
||||
|
||||
the other sources (heprep2) are copies from the FreeHEP library
|
||||
the other sources are copies from the FreeHEP library
|
||||
(java.freehep.org) and are maintained there.
|
||||
|
||||
The files starting with G4 are geant4 compliant, the others may not be.
|
||||
|
||||
Changes made here may be overwritten.
|
||||
|
||||
11 July 2003
|
||||
11 December 2003
|
||||
Mark Donszelmann
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
#include "zipios++/meta-iostreams.h"
|
||||
#include <vector>
|
||||
|
||||
#include <zlib.h>
|
||||
#include <HepRep-zlib.h>
|
||||
|
||||
#include "zipios++/filteroutputstreambuf.h"
|
||||
#include "zipios++/ziphead.h"
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <zlib.h>
|
||||
#include <HepRep-zlib.h>
|
||||
|
||||
#include "zipios++/deflateoutputstreambuf.h"
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
#include "zipios++/meta-iostreams.h"
|
||||
#include <vector>
|
||||
|
||||
#include <zlib.h>
|
||||
#include <HepRep-zlib.h>
|
||||
|
||||
#include "zipios++/filterinputstreambuf.h"
|
||||
|
||||
|
||||
@@ -14,8 +14,7 @@ typedef std::ostringstream OutputStringStream ;
|
||||
|
||||
#else
|
||||
|
||||
// MD added include strstream.h (not strstream, since it does not exist on Solaris)
|
||||
#include <strstream.h>
|
||||
#include <strstream>
|
||||
|
||||
/** OutputStringStream is typedefed to ostringstream if sstream is
|
||||
part of the standard library (unless Zipios++ has been explicitly
|
||||
@@ -24,14 +23,14 @@ typedef std::ostringstream OutputStringStream ;
|
||||
strstream.h. In this case OutputStringStream specializes the str()
|
||||
method, such that the caller does not have to concern himself with
|
||||
null-terminating the string and unfreezing the ostrstream. */
|
||||
class OutputStringStream : public ostrstream {
|
||||
class OutputStringStream : public std::ostrstream {
|
||||
public:
|
||||
|
||||
/** Specialization of ostrstream::str() that takes care of
|
||||
null-terminating the string and unfreezing the ostrstream. */
|
||||
inline string str() {
|
||||
*this << ends ; // null terminate ostrstream
|
||||
string o_str( ostrstream::str() ) ;
|
||||
*this << std::ends ; // null terminate ostrstream
|
||||
string o_str( std::ostrstream::str() ) ;
|
||||
freeze( 0 ) ;
|
||||
return o_str ;
|
||||
}
|
||||
|
||||
@@ -127,7 +127,7 @@ public:
|
||||
|
||||
/** The assignment operator doesn't copy the reference count, it
|
||||
leaves it unchanged. */
|
||||
const ReferenceCount &operator= ( const ReferenceCount &src ) {}
|
||||
const ReferenceCount &operator= ( const ReferenceCount &src ) { return *this; }
|
||||
private:
|
||||
|
||||
/** Increases the reference count. */
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <zlib.h>
|
||||
#include <HepRep-zlib.h>
|
||||
|
||||
#include "zipios++/fcoll.h"
|
||||
#include "zipios++/inflateinputstreambuf.h"
|
||||
|
||||
@@ -59,4 +59,4 @@
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#include <assert.h>
|
||||
#include <cassert>
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <zlib.h>
|
||||
#include <HepRep-zlib.h>
|
||||
|
||||
#include "zipios++/fcoll.h"
|
||||
#include "zipios++/deflateoutputstreambuf.h"
|
||||
|
||||
+6
-6
@@ -1,12 +1,12 @@
|
||||
/* zconf.h -- configuration of the zlib compression library
|
||||
/* HepRep-zconf.h -- configuration of the zlib compression library
|
||||
* Copyright (C) 1995-1998 Jean-loup Gailly.
|
||||
* For conditions of distribution and use, see copyright notice in zlib.h
|
||||
* For conditions of distribution and use, see copyright notice in HepRep-zlib.h
|
||||
*/
|
||||
|
||||
/* @(#) $Id: zconf.h,v 1.1 2003/07/11 06:01:42 duns Exp $ */
|
||||
/* @(#) $Id: HepRep-zconf.h,v 1.1 2004/02/03 19:34:43 duns Exp $ */
|
||||
|
||||
#ifndef _ZCONF_H
|
||||
#define _ZCONF_H
|
||||
#ifndef _HEPREP_ZCONF_H
|
||||
#define _HEPREP_ZCONF_H
|
||||
|
||||
/* for _LP64 */
|
||||
#include <sys/types.h>
|
||||
@@ -283,4 +283,4 @@ typedef uLong FAR uLongf;
|
||||
# pragma map(inflate_trees_free,"INTRFR")
|
||||
#endif
|
||||
|
||||
#endif /* _ZCONF_H */
|
||||
#endif /* _HEPREP_ZCONF_H */
|
||||
+14
-12
@@ -1,4 +1,4 @@
|
||||
/* zlib.h -- interface of the 'zlib' general purpose compression library
|
||||
/* HepRep-zlib.h -- interface of the 'zlib' general purpose compression library
|
||||
version 1.1.3, July 9th, 1998
|
||||
|
||||
Copyright (C) 1995-1998 Jean-loup Gailly and Mark Adler
|
||||
@@ -28,13 +28,14 @@
|
||||
(zlib format), rfc1951.txt (deflate format) and rfc1952.txt (gzip format).
|
||||
*/
|
||||
|
||||
#ifndef _ZLIB_H
|
||||
#define _ZLIB_H
|
||||
#ifndef _HEPREP_ZLIB_H
|
||||
#define _HEPREP_ZLIB_H
|
||||
|
||||
#include "zconf.h"
|
||||
#include "HepRep-zconf.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
// MD: make all functions C++ mangled
|
||||
/*extern "C" {*/
|
||||
#endif
|
||||
|
||||
#define ZLIB_VERSION "1.1.3"
|
||||
@@ -106,12 +107,12 @@ typedef z_stream FAR *z_streamp;
|
||||
|
||||
On 16-bit systems, the functions zalloc and zfree must be able to allocate
|
||||
exactly 65536 bytes, but will not be required to allocate more than this
|
||||
if the symbol MAXSEG_64K is defined (see zconf.h). WARNING: On MSDOS,
|
||||
if the symbol MAXSEG_64K is defined (see HepRep-zconf.h). WARNING: On MSDOS,
|
||||
pointers returned by zalloc for objects of exactly 65536 bytes *must*
|
||||
have their offset normalized to zero. The default allocation function
|
||||
provided by this library ensures this (see zutil.c). To reduce memory
|
||||
requirements and avoid any allocation of 64K objects, at the expense of
|
||||
compression ratio, compile the library with -DMAX_WBITS=14 (see zconf.h).
|
||||
compression ratio, compile the library with -DMAX_WBITS=14 (see HepRep-zconf.h).
|
||||
|
||||
The fields total_in and total_out can be used for statistics or
|
||||
progress reports. After compression, total_in holds the total size of
|
||||
@@ -171,7 +172,7 @@ typedef z_stream FAR *z_streamp;
|
||||
ZEXTERN const char * ZEXPORT zlibVersion OF((void));
|
||||
/* The application can compare zlibVersion and ZLIB_VERSION for consistency.
|
||||
If the first character differs, the library code actually used is
|
||||
not compatible with the zlib.h header file used by the application.
|
||||
not compatible with the HepRep-zlib.h header file used by the application.
|
||||
This check is automatically made by deflateInit and inflateInit.
|
||||
*/
|
||||
|
||||
@@ -421,7 +422,7 @@ ZEXTERN int ZEXPORT deflateInit2 OF((z_streamp strm,
|
||||
The memLevel parameter specifies how much memory should be allocated
|
||||
for the internal compression state. memLevel=1 uses minimum memory but
|
||||
is slow and reduces compression ratio; memLevel=9 uses maximum memory
|
||||
for optimal speed. The default value is 8. See zconf.h for total memory
|
||||
for optimal speed. The default value is 8. See HepRep-zconf.h for total memory
|
||||
usage as a function of windowBits and memLevel.
|
||||
|
||||
The strategy parameter is used to tune the compression algorithm. Use the
|
||||
@@ -878,7 +879,7 @@ ZEXTERN int ZEXPORT inflateInit2_ OF((z_streamp strm, int windowBits,
|
||||
inflateInit2_((strm), (windowBits), ZLIB_VERSION, sizeof(z_stream))
|
||||
|
||||
|
||||
#if !defined(_Z_UTIL_H) && !defined(NO_DUMMY_DECL)
|
||||
#if !defined(_HEPREP_Z_UTIL_H) && !defined(NO_DUMMY_DECL)
|
||||
struct internal_state {int dummy;}; /* hack for buggy compilers */
|
||||
#endif
|
||||
|
||||
@@ -887,7 +888,8 @@ ZEXTERN int ZEXPORT inflateSyncPoint OF((z_streamp z));
|
||||
ZEXTERN const uLongf * ZEXPORT get_crc_table OF((void));
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
// MD: make all functions C++ mangled
|
||||
/* } */
|
||||
#endif
|
||||
|
||||
#endif /* _ZLIB_H */
|
||||
#endif /* _HEPREP_ZLIB_H */
|
||||
+11
-10
@@ -1,19 +1,19 @@
|
||||
/* zutil.h -- internal interface and configuration of the compression library
|
||||
/* HepRep-zutil.h -- internal interface and configuration of the compression library
|
||||
* Copyright (C) 1995-1998 Jean-loup Gailly.
|
||||
* For conditions of distribution and use, see copyright notice in zlib.h
|
||||
* For conditions of distribution and use, see copyright notice in HepRep-zlib.h
|
||||
*/
|
||||
|
||||
/* WARNING: this file should *not* be used by applications. It is
|
||||
part of the implementation of the compression library and is
|
||||
subject to change. Applications should only use zlib.h.
|
||||
subject to change. Applications should only use HepRep-zlib.h.
|
||||
*/
|
||||
|
||||
/* @(#) $Id: zutil.h,v 1.4 2003/07/11 06:34:56 duns Exp $ */
|
||||
/* @(#) $Id: HepRep-zutil.h,v 1.1 2004/02/03 19:34:43 duns Exp $ */
|
||||
|
||||
#ifndef _Z_UTIL_H
|
||||
#define _Z_UTIL_H
|
||||
#ifndef _HEPREP_Z_UTIL_H
|
||||
#define _HEPREP_Z_UTIL_H
|
||||
|
||||
#include "zlib.h"
|
||||
#include "HepRep-zlib.h"
|
||||
|
||||
#ifdef STDC
|
||||
# include <stddef.h>
|
||||
@@ -216,12 +216,13 @@ extern const char *z_errmsg[10]; /* indexed by 2-zlib_error */
|
||||
|
||||
typedef uLong (ZEXPORT *check_func) OF((uLong check, const Bytef *buf,
|
||||
uInt len));
|
||||
extern "C" voidpf zcalloc OF((voidpf opaque, unsigned items, unsigned size));
|
||||
extern "C" void zcfree OF((voidpf opaque, voidpf ptr));
|
||||
// MD: made zcalloc and zcfree C++ mangled routines. see GEANT-40
|
||||
/*extern "C"*/ voidpf zcalloc OF((voidpf opaque, unsigned items, unsigned size));
|
||||
/*extern "C"*/ void zcfree OF((voidpf opaque, voidpf ptr));
|
||||
|
||||
#define ZALLOC(strm, items, size) \
|
||||
(*((strm)->zalloc))((strm)->opaque, (items), (size))
|
||||
#define ZFREE(strm, addr) (*((strm)->zfree))((strm)->opaque, (voidpf)(addr))
|
||||
#define TRY_FREE(s, p) {if (p) ZFREE(s, p);}
|
||||
|
||||
#endif /* _Z_UTIL_H */
|
||||
#endif /* _HEPREP_Z_UTIL_H */
|
||||
@@ -2,7 +2,10 @@ Mark Donszelmann - 07/07/2003
|
||||
=============================
|
||||
Functions were modified to compile with C++ compiler.
|
||||
Files renamed to .cc
|
||||
=====================================================
|
||||
Files zconf.h zlib.h and zutil.h were prefix with HepRep- (HepRep)
|
||||
to avoid clashes with the same files in /usr/include and /usr/local/include
|
||||
on unix systems.
|
||||
=============================================================
|
||||
|
||||
zlib 1.1.3 is a general purpose data compression library. All the code
|
||||
is thread safe. The data format used by the zlib library
|
||||
@@ -11,7 +14,7 @@ ftp://ds.internic.net/rfc/rfc1950.txt (zlib format), rfc1951.txt (deflate
|
||||
format) and rfc1952.txt (gzip format). These documents are also available in
|
||||
other formats from ftp://ftp.uu.net/graphics/png/documents/zlib/zdoc-index.html
|
||||
|
||||
All functions of the compression library are documented in the file zlib.h
|
||||
All functions of the compression library are documented in the file HepRep-zlib.h
|
||||
(volunteer to write man pages welcome, contact jloup@gzip.org). A usage
|
||||
example of the library is given in the file example.c which also tests that
|
||||
the library is working correctly. Another example is given in the file
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
/* deflate.h -- internal compression state
|
||||
* Copyright (C) 1995-1998 Jean-loup Gailly
|
||||
* For conditions of distribution and use, see copyright notice in zlib.h
|
||||
* For conditions of distribution and use, see copyright notice in HepRep-zlib.h
|
||||
*/
|
||||
|
||||
/* WARNING: this file should *not* be used by applications. It is
|
||||
part of the implementation of the compression library and is
|
||||
subject to change. Applications should only use zlib.h.
|
||||
subject to change. Applications should only use HepRep-zlib.h.
|
||||
*/
|
||||
|
||||
/* @(#) $Id: deflate.h,v 1.1 2003/07/11 06:01:41 duns Exp $ */
|
||||
/* @(#) $Id: deflate.h,v 1.2 2004/02/03 19:34:43 duns Exp $ */
|
||||
|
||||
#ifndef _DEFLATE_H
|
||||
#define _DEFLATE_H
|
||||
|
||||
#include "zutil.h"
|
||||
#include "HepRep-zutil.h"
|
||||
|
||||
/* ===========================================================================
|
||||
* Internal compression state.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* infblock.h -- header to use infblock.c
|
||||
* Copyright (C) 1995-1998 Mark Adler
|
||||
* For conditions of distribution and use, see copyright notice in zlib.h
|
||||
* For conditions of distribution and use, see copyright notice in HepRep-zlib.h
|
||||
*/
|
||||
|
||||
/* WARNING: this file should *not* be used by applications. It is
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* infcodes.h -- header to use infcodes.c
|
||||
* Copyright (C) 1995-1998 Mark Adler
|
||||
* For conditions of distribution and use, see copyright notice in zlib.h
|
||||
* For conditions of distribution and use, see copyright notice in HepRep-zlib.h
|
||||
*/
|
||||
|
||||
/* WARNING: this file should *not* be used by applications. It is
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* inffast.h -- header to use inffast.c
|
||||
* Copyright (C) 1995-1998 Mark Adler
|
||||
* For conditions of distribution and use, see copyright notice in zlib.h
|
||||
* For conditions of distribution and use, see copyright notice in HepRep-zlib.h
|
||||
*/
|
||||
|
||||
/* WARNING: this file should *not* be used by applications. It is
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
/* WARNING: this file should *not* be used by applications. It is
|
||||
part of the implementation of the compression library and is
|
||||
subject to change. Applications should only use zlib.h.
|
||||
subject to change. Applications should only use HepRep-zlib.h.
|
||||
*/
|
||||
|
||||
local uInt fixed_bl = 9;
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
/* inftrees.h -- header to use inftrees.c
|
||||
* Copyright (C) 1995-1998 Mark Adler
|
||||
* For conditions of distribution and use, see copyright notice in zlib.h
|
||||
* For conditions of distribution and use, see copyright notice in HepRep-zlib.h
|
||||
*/
|
||||
|
||||
/* WARNING: this file should *not* be used by applications. It is
|
||||
part of the implementation of the compression library and is
|
||||
subject to change. Applications should only use zlib.h.
|
||||
subject to change. Applications should only use HepRep-zlib.h.
|
||||
*/
|
||||
|
||||
/* Huffman code lookup table entry--this entry is four bytes for machines
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
/* infutil.h -- types and macros common to blocks and codes
|
||||
* Copyright (C) 1995-1998 Mark Adler
|
||||
* For conditions of distribution and use, see copyright notice in zlib.h
|
||||
* For conditions of distribution and use, see copyright notice in HepRep-zlib.h
|
||||
*/
|
||||
|
||||
/* WARNING: this file should *not* be used by applications. It is
|
||||
part of the implementation of the compression library and is
|
||||
subject to change. Applications should only use zlib.h.
|
||||
subject to change. Applications should only use HepRep-zlib.h.
|
||||
*/
|
||||
|
||||
#ifndef _INFUTIL_H
|
||||
|
||||
Reference in New Issue
Block a user