summaryrefslogtreecommitdiff
path: root/cpp/poppler-image.cpp
diff options
context:
space:
mode:
authorPino Toscano <pino@kde.org>2010-11-08 01:52:48 +0100
committerPino Toscano <pino@kde.org>2010-11-08 01:52:48 +0100
commitf559e77cb7d76c5fe6a79be9086667a29613c912 (patch)
treeaaeaf3dbb5042d5e755b467952f3d72d49a37faf /cpp/poppler-image.cpp
parent14dea4d74698d5d7d994e687f8176652d790dba7 (diff)
[cpp] add image::bytes_per_row()
Diffstat (limited to 'cpp/poppler-image.cpp')
-rw-r--r--cpp/poppler-image.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/cpp/poppler-image.cpp b/cpp/poppler-image.cpp
index 36f0aa89..043f97e7 100644
--- a/cpp/poppler-image.cpp
+++ b/cpp/poppler-image.cpp
@@ -242,6 +242,14 @@ int image::height() const
}
/**
+ \returns the number of bytes in each row of the image
+ */
+int image::bytes_per_row() const
+{
+ return d ? d->bytes_per_row : 0;
+}
+
+/**
Access to the image bits.
This function will detach and copy the shared data.