1

I am using the PHP GD library for image processing in my Laravel Application.

My application is deployed on AWS Lamda.

I am trying to use custom fonts in GD Library.

The function imagettftext specifically asks for the file path. Since I am on AWS Lamba, the path does not work for me.

Is there a way to use the font file stored on S3 with PHP GD?

Is there a way to input the file itself instead of the file path?

Vikas Roy
  • 854
  • 2
  • 10
  • 25

1 Answers1

0

Based on the question of the reference below, you can download the font first so maybe adding the font in a public s3 url and then run the command

imagettftext function using font from remote server

another method mentioned in the link below but its same concept http://bililite.com/blog/2012/06/04/using-imagettftext-with-off-site-font-urls/

AWS PS
  • 4,420
  • 1
  • 9
  • 22