OSSIM - Open Source Software Image Map  Version 1.9.0 (20180803)
Public Member Functions | Public Attributes | Friends | List of all members
ossimAigBounds Class Reference

#include <ossimAigBounds.h>

Public Member Functions

 ossimAigBounds ()
 
void reset ()
 
bool writeStream (std::ostream &out)
 

Public Attributes

double ll_x
 
double ll_y
 
double ur_x
 
double ur_y
 

Friends

std::ostream & operator<< (std::ostream &out, const ossimAigBounds &data)
 

Detailed Description

Definition at line 14 of file ossimAigBounds.h.

Constructor & Destructor Documentation

◆ ossimAigBounds()

ossimAigBounds::ossimAigBounds ( )

Definition at line 24 of file ossimAigBounds.cpp.

References reset().

25 {
26  reset();
27 }

Member Function Documentation

◆ reset()

void ossimAigBounds::reset ( void  )

Definition at line 29 of file ossimAigBounds.cpp.

References ll_x, ll_y, ur_x, and ur_y.

Referenced by ossimAigBounds().

30 {
31  ll_x = 0.0;
32  ll_y = 0.0;
33  ur_x = 0.0;
34  ur_y = 0.0;
35 }

◆ writeStream()

bool ossimAigBounds::writeStream ( std::ostream &  out)

Definition at line 37 of file ossimAigBounds.cpp.

References ossimEndian::getSystemEndianType(), ll_x, ll_y, OSSIM_LITTLE_ENDIAN, ossimEndian::swap(), ur_x, and ur_y.

38 {
39  ossimEndian endian;
40  double tempDouble;
41 
43  {
44  tempDouble = ll_x;
45  endian.swap(tempDouble);
46  out.write((char*)(&tempDouble), 8);
47 
48  tempDouble = ll_y;
49  endian.swap(tempDouble);
50  out.write((char*)(&tempDouble), 8);
51 
52  tempDouble = ur_x;
53  endian.swap(tempDouble);
54  out.write((char*)(&tempDouble), 8);
55 
56  tempDouble = ur_y;
57  endian.swap(tempDouble);
58  out.write((char*)(&tempDouble), 8);
59  }
60  else
61  {
62  out.write((char*)(&ll_x), 8);
63  out.write((char*)(&ll_y), 8);
64  out.write((char*)(&ur_x), 8);
65  out.write((char*)(&ur_y), 8);
66  }
67 
68  return out.good();
69 }
ossimByteOrder getSystemEndianType() const
Definition: ossimEndian.h:78
void swap(ossim_sint8 &)
Definition: ossimEndian.h:26

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  out,
const ossimAigBounds data 
)
friend

Definition at line 14 of file ossimAigBounds.cpp.

15 {
16  out << "ll_x: " << data.ll_x << std::endl
17  << "ll_y: " << data.ll_y << std::endl
18  << "ur_x: " << data.ur_x << std::endl
19  << "ur_y: " << data.ur_y;
20 
21  return out;
22 }

Member Data Documentation

◆ ll_x

double ossimAigBounds::ll_x

◆ ll_y

double ossimAigBounds::ll_y

◆ ur_x

double ossimAigBounds::ur_x

◆ ur_y

double ossimAigBounds::ur_y

The documentation for this class was generated from the following files: