News Examples Documentation Download Buy Forum Contact

Documentation

Plugins

XML Extensions

Tools


Third Party Software
for krpano

dm_Camera Plugin dm_camera.swf
by gongdeming - gongdeming@qq.com

Description

This is a panoramic shot plugin, he could attempt to carry out the current panorama shots, photographs can be saved to a local computer can also be sent to the server for sharing to a variety of social networks, supporting a variety of effects watermark overlay.

Online Demo

Click to view demo
NOTE - This plugin and the demo will work only online (no download available).

Syntax / XML Usage Example

<plugin name="camera" devices="flash" url="dm_camera.swf" 
        keep="true" width="640" height="360" handcursor="false"
        align="center" edge="center" preload="true"
        server_action="true"
        server_action_priority="false"
        onsavelocalst=""
        onsavelocaled=""
        onsavelocalel=""
        onsavelocalse=""
        onsendserverst=""
        onsendservered=""
        onsendserverer=""
>
        <watermark name="logo1" .../>
        <watermark name="logo2" .../>
        ...
</plugin>

Plugin Attributes

  • server_action
    • Upload images successfully, whether to perform server returns krpano action.
  • server_action_priority
    • When server_action = true, the server returns krpano action takes precedence in the event onsendservered.

Plugin Attributes - Events

Plugin Subnodes - <watermark>

  • With the subnode it is Defined overlay watermarks.
The <watermark> node with all settings and their default values:
<watermark name="logo1" 
           url="%SWFPATH%/skin/logo.png" 
           align="lefttop" 
           edge="lefttop" 
           x="10" 
           y="10"  
           alpha="0.5" 
           blendmode="add"
           />
		

<watermark> Attributes

  • name
  • url
    • The url / path to an image that should be used for the watermark.
  • align
    • The alignment align / anchor point of the watermark image.
      Possible values: lefttop, left, leftbottom, top, center, bottom, righttop, right, rightbottom.
  • edge
    • The alignment edge / anchor point of the watermark image.
      Possible values: lefttop, left, leftbottom, top, center, bottom, righttop, right, rightbottom.
  • x/y
    • Distance from the align point to the edge point.
  • alpha
    • Alpha value / transparency of the watermark element.
      0.0 = fully transparent, 1.0 = fully visible
  • blendmode

Plugin Actions

  • get_pic(resize,width,height,full,fillcolor)
    • Get a picture from the current view.
    • resize = Get the picture is resized(true/false) .
    • width = Specify the image width.
    • height = Specify the image height.
    • full = Are stretch the picture to specified dimensions(true/false).
    • fillcolor= Tensile sizes fill color.
  • show_pic(showWatermark)
    • Show captured image.
    • showWatermark = Whether to display the watermark(true/false).
  • hide_pic()
    • Hide captured image.
  • save_local(filename,quality,usewatermark)
    • Save the captured image to the computer.
    • filename = Save the file name.
    • quality = Save image quality(0-100).
    • usewatermark = Whether to use the saved image watermark(true/false).
  • send_server(serverpath,quality,usewatermark)
    • The captured image is sent to the server.
    • serverpath = Server interface path.
    • quality = Image quality(0-100).
    • usewatermark = Using Watermarks(true/false).
  • stop_server()
    • Stop the current server connection.
  • empty()
    • Delete Empty currently acquired image.

PHP Code

This is the server php code , receive pictures and save.
<?php
    $jpgdata = $GLOBALS["HTTP_RAW_POST_DATA"];//Image Data
    $image_filename = date("YmdHis");//File name
    if (!file_exists($image_filename.".jpg")){
$fo = fopen($image_filename.".jpg","w");
if (!fwrite($fo, $jpg)){ //Output is krpano action
echo "trace(Data write failure);";
}else{ //Output is krpano action
echo "trace(The message is returned by the server);";
echo "trace(upload is complete,the file name:".$image_filename.".jpg);";
}
} ?>

Buy / Order the plugin

NOTE - this is a commercial plugin - to use it - it must be purchased.

You can purchase this plugin through the link below.
Updates for this plugin are free!