scene-layer-control-action
Use the interface to control the PDF or webpage in the scene.
Request Mode
POST http://ip/mwapi/scene-layer-control-action
Parameter | Description |
---|---|
sceneId | The scene ID |
layerId | The layer ID |
actionType | The action type |
scaleMode | The scale mode, not required, valid only for scaling control. Scale mode includes: 0: Free 2: Height fitting canvas (PDF only) 3: Width fitting canvas (PDF only.) |
scale | The scale multiplier, not required, valid only for free scaling control. Scale multiplier *10000 |
x | The horizontal coordinates, not required, valid only for gesture control. The coordinate origin is the lower-left corner of the canvas, 0~1000000 |
y | The vertical coordinates, not required, valid only for gesture control. The coordinate origin is the lower-left corner of the canvas, 0~1000000 |
Response Body
JSON structure is as follows:
{
"sceneId":110,
"layerId":0,
"actionType":5,
"scale":10000,
"scaleMode":2,
"x":0,
"y":0
}
1. Response Status
"status": 0
Name | Description |
---|---|
status | 0 indicates a successful data acquisition. Refer to API Status Codes to find specific description for other values. |
Action Type
layer_control_action_type_none = 0,
layer_control_action_type_touch_down, // Gesture control, finger pressing
layer_control_action_type_touch_move, // Gesture control, finger moving
layer_control_action_type_touch_up, // Gesture control, finger raising
layer_control_action_type_touch_cancel, // Gesture control, cancel, same effect with finger raising
layer_control_action_type_scale, //Scale control
layer_control_action_type_go_back, //Go back, valid only for webpages
layer_control_action_type_go_forward, //Go forward, valid only for webpage
layer_control_action_type_reload, //Refresh webpage, valid only for webpage
layer_control_action_type_reset //reserved, not yet implemented