Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9160485
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T13:45:03+00:00 2026-06-17T13:45:03+00:00

I have multiple jpeg images stored as strings in memory. I want to generate

  • 0

I have multiple jpeg images stored as strings in memory. I want to generate a video from them (so those pictures would be the frames in the video).

How can I do that?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T13:45:04+00:00Added an answer on June 17, 2026 at 1:45 pm

    If you have a collection of strings that individually represents one image each, you can combine StringIO with PIL to read it without saving them to files. Then you convert from a PIL image to OpenCV by using numpy. Also, update your code to use the new OpenCV bindings.

    Here is an example that duplicates what you have (sys.argv[1] assumed to be the name of the output video file), you might need to adjust the video codec:

    import sys
    import numpy
    import cv
    import cv2
    from cStringIO import StringIO
    from PIL import Image
    
    out_video = cv2.VideoWriter()
    fourcc = cv.CV_FOURCC('D', 'I', 'V', 'X')
    fps = 30
    color = True
    
    size = None
    for fname in sys.argv[2:]:
        data = open(fname).read() # Your String
    
        s = StringIO(data)
        img = Image.open(s)
        if size and img.size != size:
            img = img.resize(size)
        else:
            size = img.size
            out_video.open(sys.argv[1], fourcc, fps, size, color)
        out_video.write(cv2.cvtColor(numpy.array(img), cv2.COLOR_RGB2BGR))
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have multiple domains on my server. I want to redirect all of them
I have multiple arrays in javascript and I want to do sum of those
We have a around 600,000 images that were converted from JPEG to TIFF files
I have merged multiple jpeg files into one single .bin file. ..... ......... while(true){
I have multiple forms for lots of products on my page and want to
I have multiple input fields on my page. I Regex them with a css
I m taking images from photo library.I have large images of 4-5 mb but
So I have a table with image sizes. There are multiple images of different
I want to use uploadify to upload my multiple images. What is scenario I
I am working on a WP7.5 application where I have to download multiple images

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.