Transform PDF to image place text on it
It sounds like you want PDF to ImageField.


  The PDF To ImageField module provides automatic conversion of uploaded
  PDF files to images. It can be used either to create a snapshot of the
  front page to use as a preview thumbnail, or to generate a gallery of
  images from each page in the document.
  
  The module is implemented as an additional widget for File Field where
  PDFs are uploaded to. It places generated images into a Image Field on
  the same content type.


That will get you half way there. As for the 2nd requirement of image merging, you'll likely have to implement your own solution via Drupal's node API/hooks to manipulate the converted PDF image with your stamp.