Skip to main content
Nathan Lovell_52
Inspiring
October 30, 2020
Question

Using Image File in Plugin UI

  • October 30, 2020
  • 1 reply
  • 246 views

How does one go about taking a local image file and putting into an AE Plugin UI?

 

Based on my searching through all the sample projects and headers/resources, it seems like newImageFromBuffer() inside of the DrawbotSuite would be the route to go. If that is the case, how do I grab a local image file, fill it into a buffer, then provide it to this function to create an arbitrary UI param?

 

Thanks!

This topic has been closed for replies.

1 reply

James Whiffin
Legend
November 6, 2020

Hi Nate

A simple way to do this is with the header only image loader stb_image. This allows you to load a local file from a path in a variety of formats. You can then copy the array of pixels to the UI via the NewImageFromBuffer that you mentioned, then DrawImage.