Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

How to use FFmpeg in NIFI?

avatar
New Contributor

How to use FFmpeg in NIFI . I want to convert Video to Tiff .

1 ACCEPTED SOLUTION

avatar
Super Mentor

@Madhav_VD 

Apache NiFi is data agnostic which makes it possible to ingest data of any format. It does this by wrapping the bytes of data in to a NiFi FlowFile.  The only thing time the content (data bytes) are read from the FlowFile would be by a NiFi processor component that would need to do so.  And only a processor specifically designed to handle the specific content type of the data would be able to do anything with the FlowFile content.

That being said, NiFi had no Content conversion processor capable of reading FFmpeg content format and writing out TIFF content format.  So the question here is how woudl you accomplish the format conversion outside of NiFi?  Perhaps this thread would help you there:
https://superuser.com/questions/881783/convert-from-avi-to-uncompressed-tiff-using-ffmpeg

NiFi in this case could still be used to automate the ingestion and conversion of your FFmpeg files by utilizing perhaps one the NiFi Scripting processors like ExecuteGroovyScript or ExecuteScript (where you can create a custom script that has some dependency on client libraries capable of doing the conversion) or maybe the ExecuteStreamCommand or ExecuteProcess processor that could call a local command line command that you pass the FlowFile content to and returns a content stream with the new Tiff format?

If you found any of the suggestions/solutions provided helped you with your issue, please take a moment to login and click "Accept as Solution" on one or more of them that helped.

Thank you,
Matt

View solution in original post

1 REPLY 1

avatar
Super Mentor

@Madhav_VD 

Apache NiFi is data agnostic which makes it possible to ingest data of any format. It does this by wrapping the bytes of data in to a NiFi FlowFile.  The only thing time the content (data bytes) are read from the FlowFile would be by a NiFi processor component that would need to do so.  And only a processor specifically designed to handle the specific content type of the data would be able to do anything with the FlowFile content.

That being said, NiFi had no Content conversion processor capable of reading FFmpeg content format and writing out TIFF content format.  So the question here is how woudl you accomplish the format conversion outside of NiFi?  Perhaps this thread would help you there:
https://superuser.com/questions/881783/convert-from-avi-to-uncompressed-tiff-using-ffmpeg

NiFi in this case could still be used to automate the ingestion and conversion of your FFmpeg files by utilizing perhaps one the NiFi Scripting processors like ExecuteGroovyScript or ExecuteScript (where you can create a custom script that has some dependency on client libraries capable of doing the conversion) or maybe the ExecuteStreamCommand or ExecuteProcess processor that could call a local command line command that you pass the FlowFile content to and returns a content stream with the new Tiff format?

If you found any of the suggestions/solutions provided helped you with your issue, please take a moment to login and click "Accept as Solution" on one or more of them that helped.

Thank you,
Matt