内容表

上一话题

Qt3DRender.QObjectPicker

下一话题

Qt3DRender.QParameter

Qt3DRender.QPaintedTextureImage

A QAbstractTextureImage that can be written through a QPainter . 更多

Inheritance diagram of PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage

概要

函数

虚函数

信号

详细描述

A QPaintedTextureImage provides a way to specify a texture image (and thus an OpenGL texture) through a QPainter . The width and height of the texture image can be specified through the width and height or size properties.

A QPaintedTextureImage must be subclassed and the virtual paint() function implemented. Each time update() is called on the QPaintedTextureImage paint() function is invoked and the resulting image is uploaded.

QPaintedTextureImage must be attached to some QAbstractTexture .

class PySide2.Qt3DRender.Qt3DRender. QPaintedTextureImage ( [ parent=None ] )
参数

parent QNode

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. height ( )
返回类型

int

另请参阅

setHeight()

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. heightChanged ( w )
参数

w int

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. paint ( painter )
参数

painter QPainter

Paints the texture image with the specified QPainter object painter .

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. setHeight ( h )
参数

h int

Sets the height ( h ) of the texture image. Triggers an update, if the size changes.

另请参阅

height()

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. setSize ( size )
参数

size QSize

Sets the width and height of the texture image. Triggers an update, if the size 改变。

另请参阅

size()

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. setWidth ( w )
参数

w int

Sets the width ( w ) of the texture image. Triggers an update, if the size changes.

另请参阅

width()

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. size ( )
返回类型

QSize

另请参阅

setSize()

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. sizeChanged ( size )
参数

size QSize

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. update ( [ rect=QRect() ] )
参数

rect QRect

Schedules the painted texture’s paint() function to be called, which in turn uploads the new image to the GPU. Parameter rect is currently unused.

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. width ( )
返回类型

int

另请参阅

setWidth()

PySide2.Qt3DRender.Qt3DRender.QPaintedTextureImage. widthChanged ( w )
参数

w int