Roku Developer Program

Join our online forum to talk to Roku developers and fellow channel creators. Ask questions, share tips with the community, and find helpful resources.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
andreV
Visitor

Canvas Item Definitions

We see the use of images and text in canvas items in many examples available both from Roku and from other developers.
Is there a strict definition of all of the available combinations of the properties that a canvas item is made up from?

i.e. { url: "http://www.domain.com/mages/image1.png"
TargetRect: {x: borderPosX,
y: borderPosY,
w: 100,
h: 100}

This makes an image item.

What other combinations of properties will the Roku identify and create an item for? Is there a document that defines this somewhere?
Can the markup be more complex and have a container for items?

i.e. {list:[
{ url: "http://www.domain.com/mages/image1.png"
TargetRect: {x: borderPosX,
y: borderPosY,
w: 100,
h: 100},
{ url: "http://www.domain.com/mages/image2.png"
TargetRect: {x: borderPosX,
y: borderPosY,
w: 100,
h: 100},
{ url: "http://www.domain.com/mages/image3.png"
TargetRect: {x: borderPosX,
y: borderPosY,
w: 100,
h: 100}
]}


thank you,

Andrej
0 Kudos
1 REPLY 1
EnTerr
Roku Guru

Re: Canvas Item Definitions

+1 to that request!
Document all working items for roCanvas (for example, it has been said elsewhere - undocumentedly - that omitting URL from above but adding color is good for painting rectangles)
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.