Logo Search packages:      
Sourcecode: djvulibre version File versions  Download package

unsigned int JB2Dict::get_memory_usage ( void   )  const

Returns the total memory used by the JB2Image. The returned value is expressed in bytes.

Reimplemented in JB2Image.

Definition at line 212 of file JB2Image.cpp.

References GArrayTemplate< TYPE >::hbound(), GArrayTemplate< TYPE >::lbound(), and GArrayTemplate< TYPE >::size().

Referenced by JB2Image::get_memory_usage().

  unsigned int usage = sizeof(JB2Dict);
  usage += sizeof(JB2Shape) * shapes.size();
  for (int i=shapes.lbound(); i<=shapes.hbound(); i++)
    if (shapes[i].bits)
      usage += shapes[i].bits->get_memory_usage();
  return usage;

Generated by  Doxygen 1.6.0   Back to index