1

Help with script involving roVideoMode.SetImageSizeThreshold()

I have a brightsign project that is simply taking a html page and displaying it through the player. The page contains a video and some images. The video is displaying perfectly; however, the images are not displaying as they are too large.

I have looked up the documentation that I need to create a script that uses roVideoMode.SetImageSizeThreshold(); however since there is very little documentation on this, I am not sure if I have used it right. If anyone could look at my script or write up a quick script on how to increase the image size, I would really appreciate it. Thanks.

My Script:

Function imgSize_Initialize(msgPort As Object, userVariables As Object, o As
Object)

print "imgSize_Initialize - entry"
print "type of msgPort is ";type(msgPort)
print "type of userVariables is ";type(userVariables)

imgSize = imgSizeBuilder(msgPort, userVariables)

return imgSize

End Function

Function imgSizeBuilder(msgPort As Object, userVariables As Object)

imgSizeBuilder = { }
imgSizeBuilder.msgPort = msgPort
imgSizeBuilder.userVariables = userVariables
imgSizeBuilder.objectName = "imgSizeBuilder_object"

imgSizeBuilder.ProcessEvent = imgSize_ProcessEvent

return imgSizeBuilder

End Function

Function imgSize_ProcessEvent(event As Object)

print "imgSize_ProcessEvent - entry"
print "type of m is ";type(m)
print "type of event is ";type(event)


if type(event)= "roVideoMode" then
if event.SetImageThreshold({4000,4000,1})
return true
else
return false
endif
endif



End Function

3 comments

  • 0
    Avatar
    Bright Scripters

    To my understanding, that method should be invoked once, during initialization.

    Something like this:

    ...

    imgSizeBuilder.ProcessEvent = imgSize_ProcessEvent

    imgSizeBuilder.vm = CreateObject("roVideoMode")
    imgSizeBuilder.vm.SetImageThreshold({4000,4000,1})

    return imgSizeBuilder
     
    Hopefully that doesn't conflict with the roVidoeMode that is in the autorun...
  • 0
    Avatar
    Lyndon

     

    The video mode object doesn't have to be persistent, so you can create it, use it, and destroy it. SO, you don't have attach it to the parent object in the plugin. 

  • 0
    Avatar
    Bright Scripters

    Good to know. So instead, code would be like:

     

    ...

    imgSizeBuilder.ProcessEvent = imgSize_ProcessEvent

    CreateObject("roVideoMode").SetImageThreshold({4000,4000,1})

    return imgSizeBuilder

Please sign in to leave a comment.