On this page:
9.28.1 Examples
9.28.1.1 Simple Picture Quad usage as a background
9.28.1.2 Simple Picture Quad usage as an overlay

9.28 PictureQuad

Use this to bring an image file as a layer into your scene. You can use it for background images, frames, ornaments, etc. Supported image formats are png (supports transparency), jpeg and bmp.

 

Parameters

 

Default

 

Range    

 

Description

 

Path

 

" "

 

n/a

 

The path of the image file

 

 

 

 

 

Quality

 

2

 

{0, 1, 2, 3}

 

  • 0: Quality_Lowest

  • 1: Quality_Lower

  • 2: Quality_Normal

  • 3: Quality_Higher

 

 

 

 

 

OnDemand

 

0

 

{0,1}

 

When 0, the image is loaded and kept alive for the life of the muvee. When 1, it is loaded only on demand to minimize texture memory consumption. Use 1 for large backgrounds that are not used in every segment. That way, you can have as many backgrounds as you want without incurring any additional texture memory overhead.

Input pattern: ()

9.28.1 Examples
9.28.1.1 Simple PictureQuad usage as a background

The simple muvee style below loads an picture background and displays the user media on top of it.

; muSE v2
 
(style-parameters)
 
(segment-durations 8.0)
 
(define muvee-global-effect (effect-stack
                                (effect "Perspective" (A))
                                (effect "CropMedia" (A))))
 
(define muvee-segment-effect    (layers (A)
                                   (effect "PictureQuad" ()
                                        (param "Path" (resource "background.jpg")))
 
                                   (effect "Scale" ()
                                        (input 0 A)
                                        (param "x" 0.8)
                                        (param "y" 0.8))))

This style does 2 main things. They are:
  • Creates a Picture using the PictureQuad effect.

  • Scales that input media to 80% of its original length. This is done so that the PictureQuad will be bigger than the user media, thus making it visible.

We have introduced the concept of layers in the example. Here’s what happens: The "PictureQuad" effect does not take any input, but we want to display the user media in front of the "PictureQuad". So we create a Layer in which we have both input A ( which is the user picture ) and the "PictureQuad" effect. That results in the nice screen shot you see below.

Do also note that the Scale effect is not written as

(effect "Scale" (A) ....)

but rather as

(effect "Scale" ()
`(input 0 A) ....)

The reason we do that is because the input media is called slightly differently within a Layers. Inside a Layers, we can use the input media without any effect by writing the letter A. Or we can use (input 0 A) if we are calling the media within an effect.

9.28.1.2 Simple PictureQuad usage as an overlay
; muSE v2
 
(style-parameters)
 
(segment-durations 8.0)
 
(define muvee-global-effect (effect-stack
                                (effect "Perspective" (A))
                                (effect "CropMedia" (A))))
 
(define muvee-segment-effect (layers (A)
                                     A
                                     (effect "PictureQuad" ()
                                             (param "Path" (resource "overlay.png")))))

In this example, we first draw the user media, denoted by the letter A. Then we draw the overlay file after it. Do note that the overlay file is a png file that has been created with a transparent region ( i.e. an alpha of 0.0 ) anywhere the overlay does not have any material of interest.