Vidu Q1 Reference to Video
Vidu AI reference to video transforms text and images into dynamic, high-quality videos effortlessly.
API
If you're looking for an API, you can choose from your desired programming language.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import requests
import base64
# Use this function to convert an image file from the filesystem to base64
def image_file_to_base64(image_path):
with open(image_path, 'rb') as f:
image_data = f.read()
return base64.b64encode(image_data).decode('utf-8')
# Use this function to fetch an image from a URL and convert it to base64
def image_url_to_base64(image_url):
response = requests.get(image_url)
image_data = response.content
return base64.b64encode(image_data).decode('utf-8')
# Use this function to convert a list of image URLs to base64
def image_urls_to_base64(image_urls):
return [image_url_to_base64(url) for url in image_urls]
api_key = "YOUR_API_KEY"
url = "https://api.segmind.com/v1/vidu-q1-reference-to-video"
# Request payload
data = {
"prompt": "A middle-aged man sits on a wooden bench in a sunny park, reading an open hardcover book titled 'Vidu Q1 Reference'. The camera gently zooms in on the book’s cover and pages showing technical content, then back to the man turning pages thoughtfully. Soft sunlight filters through the trees, blending the three reference images naturally into one smooth scene.",
"image_urls": [
"https://segmind-resources.s3.amazonaws.com/input/62d98e27-8538-4953-95e6-e93d4a544fc1-39a80c5a-c4c4-405f-88f4-30fd1a45d6c9.jpeg",
"https://segmind-resources.s3.amazonaws.com/input/ac3266d0-271e-4e31-96a9-d31f26d8c22f-a052d794-4300-478d-8d99-5a10daf5200c.png",
"https://segmind-resources.s3.amazonaws.com/input/777c247c-8073-4d47-ac64-53b5fa088aae-d9afc6d7-d3ca-4baa-8920-cb41b56ff0b8.jpeg"
],
"aspect_ratio": "16:9",
"duration": 5,
"seed": 42,
"bgm": True,
"movement_amplitude": "auto"
}
headers = {'x-api-key': api_key}
response = requests.post(url, json=data, headers=headers)
print(response.content) # The response is the generated image
Attributes
Defines the visual concept for the image. Use creative prompts to guide design style.
URLs of source images for reference. Use one URL to create a video from an image.
Sets video aspect ratio. Choose 1:1 for Instagram or 16:9 for widescreen.
Allowed values:
Controls video length. Use 5 for short clips or 10 for more detailed presentation.
Allowed values:
Determines randomization for generation. Set to 42 for consistency or 0 for variation.
min : 0,
max : 999999
Adds background music to enhance video. Enable for dynamic content or disable for silent showcase.
Configures movement strength in video. 'Auto' for default or specify for custom control.
Allowed values:
To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.
Resources to get you started
Everything you need to know to get the most out of Vidu Q1 Reference to Video
Vidu AI Reference-to-Video Usage Guide
Unlock the power of Vidu AI Reference-to-Video to create seamless multi-shot animations using your own reference images. Follow these best practices and parameter recommendations for consistent, high-quality videos.
1. Preparing Your Reference Images
- •Upload 1 to 7 high-resolution
image_urls
to guide the animation. - •Ensure images clearly show characters, objects, or scenes you want to maintain consistently.
- •Use varied angles or poses for richer multi-shot sequences.
2. Crafting Your Prompt
- •Be descriptive about the style, motion, and mood you want.
- •Example: “Animate these character images into a cinematic action sequence with dynamic camera pans and smooth transitions.”
- •Include instructions on movement amplitude, background music, or specific gestures if needed.
3. Recommended Parameters & Settings
Use Case | aspect_ratio | duration | seed | bgm | movement_amplitude |
---|---|---|---|---|---|
Character Animations | 1:1 or 4:3 | 7 | 2023 | false | auto |
Marketing Clips | 16:9 | 5 | 42 | true | auto |
Social Media Stories | 9:16 | 5 | 0 | true | auto |
Product Demos | 16:9 | 10 | 1234 | false | auto |
E-Learning Videos | 4:3 or 16:9 | 10 | 99 | false | auto |
- •Use a fixed
seed
to reproduce exact animations. - •
movement_amplitude: auto
balances natural motion with visual clarity. - •Toggle
bgm
depending on whether you want background music.
4. Workflow Tips
- •Select up to 7 reference images that represent the key visuals and poses.
- •Write a detailed prompt explaining desired actions and style.
- •Maintain consistent aspect ratio and seed across all shots for coherence.
- •Preview outputs and refine the prompt or images as needed.
- •For multi-shot videos, batch-generate using the same parameters to ensure uniformity.
5. Advanced Usage
- •Swap or add new reference images mid-project to introduce variety while preserving style.
- •Combine detailed prompts with image sets to create rich narrative sequences.
- •Use seed values to test different animation variations without changing references.
By following these guidelines, you’ll harness Vidu AI Reference-to-Video’s full potential to produce engaging, visually consistent animated videos from your own reference images.
Other Popular Models
Discover other models you might be interested in.
sdxl-img2img
SDXL Img2Img is used for text-guided image-to-image translation. This model uses the weights from Stable Diffusion to generate new images from an input image using StableDiffusionImg2ImgPipeline from diffusers

faceswap-v2
Take a picture/gif and replace the face in it with a face of your choice. You only need one image of the desired face. No dataset, no training

sdxl1.0-txt2img
The SDXL model is the official upgrade to the v1.5 model. The model is released as open-source software

sd2.1-faceswapper
Take a picture/gif and replace the face in it with a face of your choice. You only need one image of the desired face. No dataset, no training
