Extract FPDF_PAGEOBJECT properties

302 views
Skip to first unread message

Georgios Petrou

unread,
Jun 9, 2018, 4:15:07 AM6/9/18
to pdfium
I would like to extract the properties from FPDF_PAGEOBJ_PATH objects.
I found https://github.com/CaSchmidt/cslabs/blob/8173f93de88fac6384e2647b472f9a1b734f6880/cslibs/csPDFium/src/util_paths.cpp as an example, but it seems to be based on an older version of the libraries.
Are the following methods still available?
I can't find them when looking at the public header files and performing a git log -SMETHOD_NAME outputs all sorts of errors.

FPDFPathObj_CountPoints
FPDFPathObj_GetPointType
FPDFPathObj_GetPointX
FPDFPathObj_GetPointY

Dan Sinclair

unread,
Jun 11, 2018, 11:56:40 AM6/11/18
to Georgios Petrou, pdfium
I think you're looking for:

FPDFPath_CountSegments
FPDFPath_GetPathSegment
FPDFPathSegment_GetPoint
FPDFPathSegment_GetType

in the fpdf_edit.h header file.

dan


--
You received this message because you are subscribed to the Google Groups "pdfium" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pdfium+un...@googlegroups.com.
To post to this group, send email to pdf...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pdfium/52f11b6a-f32e-4e82-841b-056195b2f2e0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Georgios Petrou

unread,
Jun 12, 2018, 3:24:35 AM6/12/18
to pdfium
Thanks Dan.
One more question, do you know what units does FPDFPathSegment_GetPoint return?
I mean, pixels, points, something else?
Perhaps I should open a ticket to indicate that in the header files?

Dan Sinclair

unread,
Jun 12, 2018, 8:58:18 AM6/12/18
to Georgios Petrou, pdfium
I don't know off hand what space they're in, npm@ do you know what units the FPDFPathSegment_GetPoint returns?

And, yes, filing a bug to clarify the docs would be a great idea.

Thanks,
dan


n...@chromium.org

unread,
Jun 12, 2018, 10:10:37 AM6/12/18
to pdfium
It looks to me that they are in user space coordinates.
Reply all
Reply to author
Forward
Message has been deleted
0 new messages