Hi team,

I'm trying desperately to create a sound annotation from an uncompressed wav 
file (raw).
Adobe Reader displays an indeterminate error on opening. I find an icon (a 
speaker) but impossible to hear the sound from it.

Please find below my source code, am I on the right track?

Regards,
Christophe



PdfPage * pdfPage= _pdfDocument->GetPage(pageNum);
PdfObject pSound;
pdfPage->GetContents()->GetDictionary().AddKey(PdfName("B"),PdfVariant(static_cast<pdf_int64>(8)));
pdfPage->GetContents()->GetDictionary().AddKey(PdfName("R"),PdfVariant(static_cast<pdf_int64>(8000)));
pdfPage->GetContents()->GetDictionary().AddKey(PdfName("C"),PdfVariant(static_cast<pdf_int64>(1)));
pdfPage->GetContents()->GetStream()->Set(streamBuff,streamBuffSize);
PdfAnnotation* pAnnotation = pdfPage->CreateAnnotation(ePdfAnnotation_Sound, 
pdfrect);

pAnnotation->GetObject()->GetDictionary().AddKey( 
PdfName("Sound"),pSound.Reference() );

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Podofo-users mailing list
Podofo-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/podofo-users

Reply via email to