EMAN2
lstfastio.h
Go to the documentation of this file.
1/*
2 * Author: Steven Ludtke, 04/10/2003 (sludtke@bcm.edu)
3 * Copyright (c) 2000-2006 Baylor College of Medicine
4 *
5 * This software is issued under a joint BSD/GNU license. You may use the
6 * source code in this file under either license. However, note that the
7 * complete EMAN2 and SPARX software packages have some GPL dependencies,
8 * so you are responsible for compliance with the licenses of these packages
9 * if you opt to use BSD licensing. The warranty disclaimer below holds
10 * in either instance.
11 *
12 * This complete copyright notice must be included in any revised version of the
13 * source code. Additional authorship citations may be added, but existing
14 * author citations must be preserved.
15 *
16 * This program is free software; you can redistribute it and/or modify
17 * it under the terms of the GNU General Public License as published by
18 * the Free Software Foundation; either version 2 of the License, or
19 * (at your option) any later version.
20 *
21 * This program is distributed in the hope that it will be useful,
22 * but WITHOUT ANY WARRANTY; without even the implied warranty of
23 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 * GNU General Public License for more details.
25 *
26 * You should have received a copy of the GNU General Public License
27 * along with this program; if not, write to the Free Software
28 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
29 *
30 * */
31
32#ifndef eman__lstiofast_h__
33#define eman__lstiofast_h__ 1
34
35#include "imageio.h"
36
37namespace EMAN
38{
54 class LstFastIO : public ImageIO
55 {
56 public:
57 explicit LstFastIO(const string & fname, IOMode rw_mode = READ_ONLY);
58 ~LstFastIO();
59
61 static bool is_valid(const void *first_block);
62
64 {
65 return false;
66 }
67 int get_nimg();
68 private:
70 int nimg;
71 unsigned int line_length;
72 unsigned int head_length;
73
76
79
80 int calc_ref_image_index(int image_index);
81 static const char *MAGIC;
82 };
83
84}
85
86
87#endif //eman__lstio_h__
ImageIO classes are designed for reading/writing various electron micrography image formats,...
Definition: imageio.h:127
IOMode rw_mode
Definition: imageio.h:353
A LSX file is a high performance ASCII file that contains a list of image numbers and file names.
Definition: lstfastio.h:55
unsigned int line_length
Definition: lstfastio.h:71
unsigned int head_length
Definition: lstfastio.h:72
static bool is_valid(const void *first_block)
Definition: lstfastio.cpp:111
int get_nimg()
Return the number of images in this image file.
Definition: lstfastio.cpp:235
int calc_ref_image_index(int image_index)
Definition: lstfastio.cpp:138
bool is_big_endian
Definition: lstfastio.h:69
string ref_filename
Definition: lstfastio.h:75
LstFastIO(const string &fname, IOMode rw_mode=READ_ONLY)
Definition: lstfastio.cpp:52
bool is_single_image_format() const
Is this image format only storing 1 image or not.
Definition: lstfastio.h:63
static const char * MAGIC
Definition: lstfastio.h:81
int last_lst_index
Definition: lstfastio.h:77
ImageIO * imageio
Definition: lstfastio.h:74
int last_ref_index
Definition: lstfastio.h:78
E2Exception class.
Definition: aligner.h:40