Video Texture Module Resolution? I got this script from a tutorial:
http://www.tutorialsforblender3d.com/Game_Engine/VideoTexture/VideoTexture_Render_1.html

It allows to set a video texture In the game that's is a render of a camera in real time. For making security cameras monitors for example.
 The only thing I need is to add a command line to scale down the resolution and it will be good to go.
Can Someone Help? See the File.


Script:

import bge

# get current scene
scene = GameLogic.getCurrentScene()

# get the current controller
controller = GameLogic.getCurrentController()

# get object script is attached to
obj = controller.owner

# check to see RenderToTexture has been added
if obj.has_key("RenderToTexture") == True:

    # update the texture
    obj["RenderToTexture"].refresh(True)

    # if RenderToTexture hasn't been added 
else:

    # import VideoTexture module
    import VideoTexture

    # get a list of objects in the scene
    objList = scene.objects

    # get camera name being used for render to texture
    camName = obj['cam']

    # get camera object
    cam = objList["OB" + camName]

    # get the texture material ID
    matID = VideoTexture.materialID(obj, "MA" + obj['material'])

    # set the texture
    renderToTexture = VideoTexture.Texture(obj, matID)

    # get the texture image
    renderToTexture.source = VideoTexture.ImageRender(scene,cam)

    # save RenderToTexture as an object variable
    obj["RenderToTexture"] = renderToTexture
When setting up the image source specify a capsize.

e.g.:

source.capsize = [50, 50]


Based on your code:

BGE 2.50+

setup

import bge

controller = bge.logic.getCurrentController()
owner = controller.owner

cameraName = owner['cam']
materialName = owner['material']

scene = bge.logic.getCurrentScene()
camera = scene.cameras[cameraName]

materialId = bge.texture.materialID(owner, "MA" + materialName)

renderToTexture = bge.texture.Texture(owner, materialId)
owner["RenderToTexture"] = renderToTexture

source = bge.texture.ImageRender(scene, camera)
source.capsize = [50, 50]
renderToTexture.source = source


refresh

import bge

controller = bge.logic.getCurrentController()
controller.owner["RenderToTexture"].refresh(True)




BGE 2.49

setup

import GameLogic
import VideoTexture

controller = GameLogic.getCurrentController()
owner = controller.owner

cameraName = owner['cam']
materialName = owner['material']

scene = GameLogic.getCurrentScene()
camera = scene.cameras["OB" + cameraName]

materialId = VideoTexture.materialID(owner, "MA" + materialName)

renderToTexture = VideoTexture.Texture(owner, materialId)
owner["RenderToTexture"] = renderToTexture

source = VideoTexture.ImageRender(scene, camera)
source.capsize = [50, 50]
renderToTexture.source = source


refresh

import GameLogic

controller = GameLogic.getCurrentController()
controller.owner["RenderToTexture"].refresh(True)