Saving image with data in QVariant

JPEG image is converted to QVariant (with bb::cascades:Image) by using the following code

m_image is bb::cascades:Image

m_image = bb::cascades:Image (imageData);

Converted to QVariant using QVariant::fromValue (m_image)

The image is displayed in qml. (I can't save the file immediately after uploading there will be a lot of pictures and I have to select and save.) When the image is displayed his QVariant...

I would like to save this image, who subsequently to use as Photo of Contact...

I saw the code example

imageData1 is QByteArray

Image image = QImage::fromData (imageData1, "BMP");
QFile outFile("shared/photos/temp1.bmp"); change the path to your file
outFile.open (QIODevice::WriteOnly);
image. Save (& outFile, "JPEG");

I tried to convert the QVariant to QByteArray using QVariant.toByteArray (). but it did not work.

Any help will be really appreciated...

The problem is solved by standing around ImageData object of data instead of the Image object. By using the following code...

Demonstration of QByteArray = ImageConverter::encode ("image/jpeg", myImageData);
QImage image = QImage::fromData (demonstration, "JPEG");
QString imgPath = "shared/photos/"+myImageName+".jpg";

If (!) QFile::exists(imgPath))))
{
QFile outFile (imgPath);

outFile.open (QIODevice::WriteOnly);
image. Save (& outFile, "JPEG");
}

Tags: BlackBerry Developers

Similar Questions

  • How to remove the image with a single click?

    Hello friends, I want a help with something simple.

    I want to open my app when displaying an image with data or information and clicking on, get out and show me the menu of the application as usual.

    My picture is this:

    seen in my application, but I can't make it go away

    Solution:

         ImageButton {
                    id: imageView02
    
                    defaultImageSource: "asset:///images/IMG_00000014.png"
                    onClicked: {
                        imageView02.visible = false
                    }
                }
    
  • Saving binary Image with overlay?

    Hello

    I'm having some trouble in saving an image with overlay information. I use IMAQ find circles to measure the rays of the holes in a binary image. Hole data is then used with oval Overlay IMAQ, draw on ovals to highlight detected circles. Works very well and the image is displayed as expected in the output of the image on the screen, the palette has the binary value. (See the second image of 3, below)

    When I try and save the image in PNG I just get a blank image (black). If I use the overlay IMAQ merge tool, I just get the green circles on the black (see the last picture of 3 below). Is there something I'm missing with pallets/fusion? Any help much appreciated. Snapshot of the (messy) code attached.

    The problem is that the binary image is all zeros and ones.  A normal image goes up to 255, so the value 1 appears black.

    One solution is to multiply the binary image of 255, which makes the image black and white.

    Bruce

  • Preview of the scanned image is good but once saved image is black with horizontal lines

    My OS is: OSX 10.9.3

    I have a HP Photosmart Premium series - C309g all-in-one machine. This machine worked well.

    Print is good.

    Copy is good.

    But now I have some analysis of the issues, probably due to an update of the OS.

    Problem: Preview of the scanned image is good, but what saving image--> the image is black with horizontal lines.

    I rumaged through the forums and you have not yet found a solution to my specific machine.

    Any help would be greatly appreciated.

    Thank you!

    Hello

    Scan using the software provided as Capture of Image or preview.

    The application of scanning HP for your printer is not available to 10.9, you use incompatible software.

    Follow these steps to get the results of the analysis required:

    http://support.HP.com/us-en/document/c04028214

    Shlomi

  • Executives ignored in the acquisition of images with 4 Configuration of the camera (cards 2 x 1430), record only half of the expected data

    Hi all

    I have a VI that puts in place a continuous grab for four camera link cameras at 100 Hz (512 x 640).  I have the cameras running on an external clock of 100 Hz for synchronization (comes from box NI DAQ, trigger ports on 1430 cards are not connected to anything).  The VI sticks all the frames in a queue, and then I (slowly) he writes to disk after that I get what I want.

    The problem is, for a minute 4 capture, I get only about 14 000 items in the queue instead of 24 000.  Also, each image gets populated with a number of buffer, so I can see it is missing all the other images or something like that, sometimes it will jump 10 in a row, sometimes it will jump rare... any ideas?

    Here is a picture of my installation of collection (Scripture on the part of the disk is not displayed, but that pours out of the queue is fine)-

    Hello

    I see a number of problems with the approach in your VI that I'll try to cover...

    Your consumption with queues and images won't work as you wrote because the images are a type of reference data and so put them in the queues is not copy data values, only the references. So if you keep to the same reference to the image in a queue, they are all pointing to the same data of the image (which may be substituted).

    A better approach is to have two queues of images, representing the 'free' pads and then one that represents the images 'full' (your queue current consumer). You would then have your acquisition loop pull a 'free' image, fill it with data via a Get buffer call and then queue it for your use. Your consumer could pull this queue, do its thing and then queue the image to the queue 'free' for the producer to use again.

    In addition, your code does not currently use the lower level is VI buffer, so you take advantage of the buffering model input-output IMAQ uses internally. The simple Grab acquire VI returns only the most recent image, but if you fall at all it does not use the FIFO. You want to call make buffer with a buffer incremeenting number so that you do not skip the buffers and are allowed to get behind up to the number of buffers in the buffers configured list.

    Eric

  • Loading videos photos with date information incorrectly (1970-1-1)

    A day after the update my version of osx from Yosemite to El Capitan, when I import pictures from my camera, I find that the images are imported with the correct date information while the videos are not. I check the date of editing these videos which is correct, so I think that this problem has nothing to do with my camera.  Everything works fine when I use Yosemite also turns out at this point. So, how can I know it?

    The problem is, that the photos have EXIF tags with the date of capture, but the videos do not have this EXIF tag.

    Photos uses instead the creation date of the file.

    Use the command "Image > adjust date and time" in photos to change the date of your videos to the date of change.  This workaround is a lot of extra work, but right now there is no help for it.

    You can send comments to the bug report to Apple, that the creation date of the file is lost during import.  Comments - Photos - Apple

    Using iCloud photo library?  I saw the creation date changes when videos are synchronized with iCloud.

  • How can I import an image with transparent background .png in the Vision Assistant?

    Hello

    I am using the Vision Assistant of NOR. Here, I want to overlay one existing image with another. Therefore, I use the overlay Installer where can I import a .png image. If I do, I don't get

    the transparent background of the back of the image, even, I was saved with a transparent background. The image is displayed with an orange background.

    If I import the same image to any front panel for example, I see the picture on the right path with a transparent background. What I've done wrong? I have attached the image I want to use.

    Thank you

    Hello! Don't know how to do this in the Vision Assistant. Try to use the overlay (bitmap) or convert your image into mask. Effect of transparency not supported in the Vision. What you can do in LabVIEW is something like this:

  • HP Photosmart B8550 print any pictures of my saved images

    Windows 8 with THE 32 and 64 bit.  I can print everything but my saved pictures.  I have to put it on a memory stick or a card to print.   Is this problem with the printer or Windows 8?

    Hi thanks for the reply could you please open this image with another application by right-clicking on the image and selecting "Open with" and choose another application from there. Let me know what happens when you do that.

    To help an employee of HP.

    * Say thank you by clicking on the "Bravo!" Star"located on the left *.

    * Make it easier for others to find solutions, marking my answer to "Accept as Solution" if it solves your issue.*

  • No image with customized image of Windows 10 Acer Iconia W510

    I'm trying machines Acer Iconia W510 image with an image of Windows 10 we did. We have already photographed a few tens of individuals. A dozen, however, refuse to take the picture. They are currently on Windows 8. The image on an external hard drive that plug us into the USB port.

    The steps I take to the imaging process are as follows: "Change PC settings"->"update and recovery"-> "recovery"->"Advanced startup" and I click on the button 'Restart now', who sends me to a screen with three options, continue to windows 8.1, troubleshooting, and turn off your PC.

    I select 'Troubleshoot '->' Advanced'-> "Image system recovery"

    The Acer screen appears with "Preparation of the system image recovery" at the bottom. I sign in the administrator account when prompted to choose an account.

    A window appears and scans for images. I selected the "Select a system image" option and then select the correct image of Windows 10.

    Then, I select the only available option for "select the date and time of the system image to restore.

    After that, there is a message that says "for the restoration of this computer, needs of Windows to format the drive that the Windows recovery environment is running on." To continue with the restore, shut down this computer and it boot from a Windows installation disc or a disc repair system, then try the restore again. "At this point, I have no way to continue.

    Even if I plug the USB recovery drive we used, I get the same message. I don't know what the problem is or how to get past. Any help is appreciated!

    Hi Ryan,

    According to the description, you can not install updates and the this issue may occur if one or more of the following conditions are met: 

    1. The Windows Update database is damaged.
    2. Antivirus software is configured to scan the folder % Windir%\SoftwareDistribution.
    3. Service (BITS) Background Intelligent Transfer Service does not receive a content link header.
    4. A required system file is incorrectly registered.

    Try it out below mentioned methods and see if it works for you.

    Method 1

    First of all, I suggest you run Windows update troubleshooting tool to get the problem automatically detected and corrected. This fixit checks the configuration of the Windows Update components and repairs, fixes incorrect Windows Update the locations of data and records of necessary services. For the race, the troubleshooter refer to sub article what can I do if I have problems to install updates.

    Windows Update: FAQ

    Method 2

    I suggest you to check if you are able to access Windows Update services and also make sure that the following services are started. If it is not started, follow the listed below as follows:

    a. press the Windows key + R, type "services.msc" (without the quotes) in the Run dialog box to start, and press enter.

    b. Locate the Windows Update service.

    c. right-click on the Windows Update service and select Properties.

    d. in Startup type, select enable.

    e. click Start under Service status.

    f. click OK.

    g. Repeat steps c to f for the following services :

    CSP & Background Intelligent Transfer Service.

    If these steps do not help to solve the problem, you can proceed to the step below and check.

    Method 3

    If the problem persists I suggest to reset the Windows Update components and for this, try to run the fixit described in the following article. If you already tried the fixit even before that I ask of you rerun the fixit.

    How to reset the Windows Update components?

    http://support.Microsoft.com/kb/971058/en-us#LetMeFixItMyselfAlways

    Keep us.

    Kind regards

  • Georaster: Import very large images with sdo_geor.importFrom

    Hello

    What is the best way to import images of very large (> 50 GB) (GeoTIFF, TIFF, etc.) in a table georaster. Actually I don't have the image in a single file, but in raster 1 GB files.

    Approach 1:

    Import each image 1 GB with sdo_geor.importFrom block into small tiles (block settings) within the oracle and merge 50 rasters then into a large raster object using SDO_GEOR.mosaic. It is a recommended method?

    Approach 2:

    Create the actual tiles of all images with GDAL. Is it possible to import directly the tiles with meta-information into a table of raster data?

    Thanks for your suggestions on this matter.

    Yes, for Linux, you will need to compile it yourself. I did it without too much trouble on Centos.

    But the most straightforward approach is to download and install the latest QGIS for Windows. The grouped GDAL is up-to-date and includes the hooks of the OIC.

    See you soon,.

    Paul

  • Need a Script to the space of images on a total gap, then tag each image with the percentage of the total image space

    By editing the other scripts, I found here and other sites (including the labels size rorohiko), I worked on a script that will each image with the dimensions of the label and calculate the percentage of the spread of everything (including the text, white space).

    Now, I was invited to a script that tagged the images with the percentage of total image on a gap space. This script is so space images on a total gap, then tag each image with the percentage of the total image space. For example if there is an image that is 10 x 10 inches and four pictures that are images of 2.5x2.5, 10 x 10 would be tagged with 50% and the 2.5x2.5 would be tagged with 12.5%.

    This is the script that does the percentage of total circulation. Can some clever person get to do what I need?

    Suze

    (Sorry, I don't know how to post the script here with line numbers!)

    //

    This script adds printing of information labels to each graphic image. The labels are on a separate layer

    named "PercentageLabels" so that all these added labels can be removed again by simply removing

    the layer.

    //

    If you move or resize items, simply re-run the script to update the labels.

    //

    Before (re) start the script, you can define a paragraph style "SizeLabelStyle".

    This style will apply to all content on labels.

    //

    Before (re) start the script, you can set a style of object 'SizeLabelObjectStyle '.

    This style of object apply to all executives of the label - so if you want a specific background

    fill out or frame, do it through this object style.

    //

    You can change the units of the size label. I put in inches. Change the line below that has

    kUnitToUse - you can use:

    MeasurementUnits.CENTIMETERS

    MeasurementUnits.CICERO

    MeasurementUnits.INCHES

    MeasurementUnits.MILLIMETERS

    MeasurementUnits.PICAS

    MeasurementUnits.PIXELS

    MeasurementUnits.POINTS

    //

    By default the script will not attempt to label the "nested" images If you also want to label

    nested images (for example inline images, anchored frames, pasted images in the images,...) to change the line

    below to read:

    kLabelNestedItems = 1

    //

    If you want a specific image to stay without a label, you can use the Script label palette for

    assign a script called 'ignore' for this frame. The script will then not label this framework to the

    the title of the script is removed again.

    //

    Change the lines with kDontLabelImageFrames, kDontLabelTextFrames, kDontLabelOtherFrames

    below if you want to restrict labelling to only certain types of images: replace the '0'

    in "1" to enable these options.

    //

    Change the line with kShowImageFileName if you also want to display the names of the image in the

    size for the picture frames.

    //

    Small frames are not labelled - the cutoff point is currently a less than 0.1 inch high framework

    or 0.1 inch wide. You can change the cutoff point by adjusting the lines with kDontLabelBelowWidth

    or kDontLabelBelowHeight below.

    //

    var Girard;

    var gScriptFile;

    var gCaches;

    // ****************

    That's cheating spread automatically calculated

    var doc = app.activeDocument;

    doc.viewPreferences.horizontalMeasurementUnits = MeasurementUnits.inches;

    doc.viewPreferences.verticalMeasurementUnits = MeasurementUnits.inches;

    PageWidth = doc.documentPreferences.pageWidth var;

    stucture var pagewidth = * 2;

    var spreadheight = doc.documentPreferences.pageHeight;

    var spreadsquinch = stucture * spreadheight;

    Alert ("the total measure of square inch of spread is:" + spreadsquinch);

    //******************

    VR;

    {

    If (app.activeScript instanceof file)

    {

    var gScriptFile = app.activeScript;

    }

    }

    catch (Girard)

    {

    }

    If (typeof (kLogLevel) is "undefined")

    {

    const kLogLevel = 5;

    const kMaxLogNestLevel = 5;

    const kLogToMessageBox = 0;

    const kLogToConsole = 0;

    const kLogToFile = 0;

    const kLogFileName = "PercentageLabels.log";

    const kIgnoreFrameLabel = "ignore."

    const kSizeLabelLayerName = "PercentageLabels";

    const kLabelNestedItems = 0;

    const kDontLabelImageFrames = 0;

    const kDontLabelTextFrames = 1;

    const kDontLabelOtherFrames = 0;

    const kUnitToUse = MeasurementUnits.INCHES;

    const kShowImageFileName = 0; This set to 1 to precede the name of the image file in the tag

    Below all of the measures are expressed in kUnitToUse (e.g. inches if MeasurementUnits.INCHES is used)

    const kRoundToDecimals = 2;

    The separator to use between objects - for example MyImage.jpg - 7.22 x 9,34

    const kSeparatorBetweenNameAndSize = "-";

    const kSeparatorBetweenHeightAndWidth = "H x"; "

    const kSeparatorAfterWidth = "W";

    const kDontLabelBelowWidth = 0.1; In kUnitToUse

    const kDontLabelBelowHeight = 0.1; In kUnitToUse

    const kLabelStyleName = "SizeLabelStyle";

    const kLabelObjectStyleName = "SizeLabelObjectStyle";

    const kLabelHeight = 0.6; In kUnitToUse

    const kLabelWidth = 2.5; Expressed in kUnitToUse (e.g., inches).

    }

    var gRunState =

    {

    logToMessageBox: kLogToMessageBox,

    logToConsole: kLogToConsole,.

    logToFile: kLogToFile,.

    functionNestLevel: 0,

    logFunctionEntry: true,

    logFunctionExit: true,

    logLevel: kLogLevel,.

    logFileName: kLogFileName

    };

    Main();

    // ****************

    function ConvertToFrame (thePageItem)

    {

    / * / / / LogEntry ("ConvertToFrame");

    var retVal = thePageItem.getElements () [0];

    / * / / / LogExit ("ConvertToFrame");

    Return retVal;

    }

    // ****************

    function CollectionToArray (theCollection)

    {

    / * / / / LogEntry ("CollectionToArray");

    var retVal = theCollection.everyItem () .getElements () .slice (0);

    / * / / / LogExit ("CollectionToArray");

    Return retVal;

    }

    // ****************

    function GetImageFile (pageItem)

    {

    / * / / / LogEntry ("GetImageFile");

    var imageFile = null;

    do

    {

    Try

    {

    pageItem = ConvertToFrame (pageItem);

    If (!) (("allGraphics" in pageItem))

    {

    break;

    }

    var allGraphics = pageItem.allGraphics.slice (0);

    If (allGraphics.length == 0)

    {

    break;

    }

    var chart = allGraphics [0];

    var graphic.itemLink = link;

    imageFile = new File (link.filePath);

    }

    catch (Girard)

    {

    }

    }

    While (false);

    / * / / / LogExit ("GetImageFile");

    return imageFile.

    }

    // ****************

    function GetImageName (pageItem)

    {

    / * / / / LogEntry ("GetImageName");

    var imageName = "";

    do

    {

    var imageFile = GetImageFile (pageItem);

    If (imageFile is nothing)

    {

    break;

    }

    imageName = imageFile.displayName;

    }

    While (false);

    / * / / / LogExit ("GetImageName");

    return imageName;

    }

    // ****************

    function GetOuterPageItem (pageItem)

    {

    / * / / / LogEntry ("GetOuterPageItem");

    var retVal = null;

    do

    {

    Try

    {

    retVal = pageItem.parent;

    If (retVal instanceof spread | retVal instanceof Page)

    {

    retVal = pageItem;

    break;

    }

    If (retVal instanceof character)

    {

    retVal = GetOuterPageItem(retVal.parentTextFrames[0]);

    break;

    }

    }

    catch (Girard)

    {

    retVal = null;

    }

    }

    While (false);

    / * / / / LogExit ("GetOuterPageItem");

    Return retVal;

    }

    // ****************

    function LogMessage (message, collapseLines)

    {

    If (gRunState.logToConsole)

    {

    $.writeln (message);

    }

    If (gRunState.logToFile)

    {

    var logFile = new file (gScriptFile.parent + "/" + gRunState.logFileName);

    var now = new Date();

    logFile.open ("a");

    logFile.write (now.toString () + ":"+ message + "\n" ');

    logFile.close ();

    }

    If (gRunState.logToMessageBox)

    {

    Alert (message);

    }

    }

    // ****************

    LogEntry (message) function

    {

    If (gRunState.logFunctionEntry)

    {

    If (gRunState.functionNestLevel < kMaxLogNestLevel) {}

    for (var idx = 0; idx < gRunState.functionNestLevel; idx ++)

    {

    message = "" + message;

    }

    Filled (message + "<", true);

    }

    }

    gRunState.functionNestLevel ++;

    }

    // ****************

    function LogError (message)

    {

    If (gRunState.logLevel > = 1).

    {

    LogMessage ("* ERROR *:" + message, false);

    }

    }

    // ****************

    function LogExit (message)

    {

    -gRunState.functionNestLevel;

    If (gRunState.functionNestLevel < 0)

    {

    LogError ("LogExit: unbalanced nesting of function");

    }

    If (gRunState.logFunctionExit)

    {

    If (gRunState.functionNestLevel < kMaxLogNestLevel) {}

    for (var idx = 0; idx < gRunState.functionNestLevel; idx ++)

    {

    message = "" + message;

    }

    Filled (message + ">", true);

    }

    }

    }

    // ****************

    function LogNote (message)

    {

    If (gRunState.logLevel > = 3)

    {

    LogMessage ("Note:" + message, false);

    }

    }

    // ****************

    function LogWarning (message)

    {

    If (gRunState.logLevel > = 2)

    {

    LogMessage ("WARNING:" + message, false);

    }

    }

    // ****************

    function Main()

    {

    / * / / / LogEntry ("Main");

    var savedUserInteractionLevel = app.scriptPreferences.userInteractionLevel;

    app.scriptPreferences.userInteractionLevel = UserInteractionLevels.NEVER_INTERACT;

    do

    {

    Try

    {

    activeDocument var = app.activeDocument;

    If (!.) (activeDocument instanceof Document))

    {

    LogError ("hand: activeDocument isn't a Document");

    break;

    }

    var savedHorizontalMeasurementUnits = activeDocument.viewPreferences.horizontalMeasurementUnits;

    activeDocument.viewPreferences.horizontalMeasurementUnits = kUnitToUse;

    var savedVerticalMeasurementUnits = activeDocument.viewPreferences.verticalMeasurementUnits;

    activeDocument.viewPreferences.verticalMeasurementUnits = kUnitToUse;

    var savedRulerOrigin = activeDocument.viewPreferences.rulerOrigin;

    activeDocument.viewPreferences.rulerOrigin = RulerOrigin.PAGE_ORIGIN;

    do

    {

    Try

    {

    ProcessFrames (activeDocument);

    }

    catch (Girard)

    {

    Alert ("the script encountered a situation that we don't know how to handle. "He received the error, says '" + Parker + "' in Main()"); "."

    }

    }

    While (false);

    activeDocument.viewPreferences.rulerOrigin = savedRulerOrigin;

    activeDocument.viewPreferences.horizontalMeasurementUnits = savedHorizontalMeasurementUnits;

    activeDocument.viewPreferences.verticalMeasurementUnits = savedVerticalMeasurementUnits;

    }

    catch (Girard)

    {

    Alert ("the script encountered a situation that we don't know how to handle. "He received the error, says '" + Parker + "' in Main()"); "."

    LogError ("Hand throw" + Girard);

    }

    }

    While (false);

    app.scriptPreferences.userInteractionLevel = savedUserInteractionLevel;

    / * / / / LogExit ("Main");

    }

    // ****************

    function ProcessFrames (doc)

    {

    / * / / / LogEntry ("ProcessFrames");

    var err;

    do

    {

    If (!.) (doc instanceof Document))

    {

    LogError ("ProcessFrames: doc should be a Document");

    break;

    }

    Try

    {

    var existingLayer = doc.layers.itemByName (kSizeLabelLayerName);

    existingLayer.id;

    existingLayer.remove ();

    }

    catch (err)

    {

    }

    If (kLabelNestedItems)

    {

    var pageItems = doc.allPageItems.slice (0);

    }

    on the other

    {

    var pageItems = CollectionToArray (doc.pageItems);

    }

    var frameReferences = [];

    for (var pageItemIdx = 0; pageItemIdx < pageItems.length; pageItemIdx ++)

    {

    do

    {

    var pageItem = pageItems [pageItemIdx];

    If (pageItem.itemLayer.name is kSizeLabelLayerName)

    {

    break;

    }

    var pageItem = ConvertToFrame (pageItem);

    If (instanceof TextFrame pageItem)

    {

    If (kDontLabelTextFrames)

    {

    break;

    }

    }

    ElseIf (pageItem graphic instanceof)

    {

    If (kDontLabelImageFrames)

    {

    break;

    }

    }

    on the other

    {

    If (kDontLabelOtherFrames)

    {

    break;

    }

    }

    If (pageItem.label.toLowerCase () is kIgnoreFrameLabel)

    {

    break;

    }

    var width = pageItem.geometricBounds [3] - pageItem.geometricBounds [1];

    var height = pageItem.geometricBounds [2] - pageItem.geometricBounds [0];

    If (width < kDontLabelBelowWidth)

    {

    break;

    }

    If (height, kDontLabelBelowHeight)

    {

    break;

    }

    frameReferences.push (pageItem);

    }

    While (false);

    }

    var sizeLabelLayer = doc.layers.add ({name: kSizeLabelLayerName});

    for (var pageItemIdx = 0; pageItemIdx < frameReferences.length; pageItemIdx ++)

    {

    Try

    {

    var pageItem = frameReferences [pageItemIdx];

    var width = pageItem.geometricBounds [3] - pageItem.geometricBounds [1];

    var height = pageItem.geometricBounds [2] - pageItem.geometricBounds [0];

    var labelItem = doc.textFrames.add (null, LocationOptions.BEFORE, GetOuterPageItem (pageItem));

    labelItem.itemLayer = sizeLabelLayer;

    var boxsquinch = width * height

    var boxpercent = (boxsquinch / spreadsquinch) * 100

    var roundpercent = Math.round (boxpercent)

    var labelText = "";

    If (kShowImageFileName)

    {

    var imageName = GetImageName (pageItem);

    If (imageName! = "")

    {

    labelText += imageName + kSeparatorBetweenNameAndSize;

    }

    }

    labelText += RoundString (height, kRoundToDecimals) + kSeparatorBetweenHeightAndWidth + RoundString(width, kRoundToDecimals) + kSeparatorAfterWidth + ' \r\n'+ roundpercent + '% ';

    labelItem.contents = labelText;

    xPos = pageItem.geometricBounds var [1];

    yPos = pageItem.geometricBounds var [0] + kLabelHeight;

    labelItem.geometricBounds is [Posy, xPos, yPos + kLabelHeight, xPos + kLabelWidth];.

    Try

    {

    labelItem.parentStory.characters.everyItem () .appliedCharacterStyle = doc.characterStyles.item (0);

    }

    catch (err)

    {

    }

    Try

    {

    labelItem.parentStory.paragraphs.everyItem () .appliedParagraphStyle = kLabelStyleName;

    }

    catch (err)

    {

    }

    Try

    {

    labelItem.appliedObjectStyle = doc.objectStyles.itemByName (kLabelObjectStyleName);

    }

    catch (err)

    {

    }

    }

    catch (err)

    {

    }

    }

    }

    While (false);

    / * / / / LogExit ("ProcessFrames");

    }

    // ****************

    function RoundString (numVal, decimal)

    {

    / * / / / LogEntry ("Round");

    var retVal = Math.round (numVal * Math.pow(10,decimals)) + "";

    retVal = retVal.substring(0,retVal.length-decimals) + "." + retVal.substring(retVal.length-decimals);

    / * / / / LogExit ("Round");

    Return retVal;

    }

    What do you mean?

    var myDoc = app.activeDocument;
    var mySpreads = myDoc.spreads;
    var myRectangles = myDoc.rectangles;
    var myImages = 0;
    for (var i = 0; i < mySpreads.length; i++) {
        var mySpreadWidth = 0;
        var mySpreadHeight = myDoc.documentPreferences.pageHeight;
        for (var j = 0; j < mySpreads[i].pages.length; j++) {
            mySpreadWidth += myDoc.documentPreferences.pageWidth;
            }
        var mySpreadArea = mySpreadWidth * mySpreadHeight;
        var myImages = mySpreads[i].rectangles;
        var myTotalImageArea = 0;
        var myIndividualImageArea = [];
        for (var j = 0; j < myImages.length; j++) {
            var myImageGeometricBounds = myImages[j].geometricBounds;
            var myImageWidth = myImageGeometricBounds[3] - myImageGeometricBounds[1];
            var myImageHeight = myImageGeometricBounds[2] - myImageGeometricBounds[0];
            myIndividualImageArea[j] = (myImageWidth * myImageHeight);
            myTotalImageArea += myIndividualImageArea[j];
            }
        for (var j = 0; j < myIndividualImageArea.length; j++) {
            alert("Image percentage of total images on spread " + (i + 1) + " = " + (myIndividualImageArea[j] * 100) /myTotalImageArea);
            }
       alert("Total image percentage on spread " + (i + 1) + " = " + myTotalImageArea);
       }
    
  • automate the image with the previous editions

    Hi everyone thanks for your time.

    I need to make a very difficult task for me, I have a text of the circle, I need to create an action to rotate the text of circle 1.8 degrees, save it and turn then 1.8 degrees of the previous saved image, it must be done 200 times, briefly, to rotate image save 1.8 °, rotation of previous saved 1.8 ° rotation of previous recorded 1.8 °, turn from previous recorded 1.8 °... until he reach 200 rotations.

    Thank you very much.

    You can also create text on a path may convert into a form to stroke and fill.  Rotate this layer with a script I posted. The displacement of the 200 out of the layer group the script layer put them in remove the Group layer and the background. Create an animation of image and make the frames from the 200 layers.   If the interpolation does not work for you. I never tried to tween and rotation of the transformation. Do not the size of the large canvas this gif of 800x800px is 4 MB in size. I used the script I posted to create 200 layers. Made of the MP4 mod is also 4MB turned faster on a black background video does not support transparent backgrounds. The video is so white letters on black background. You don't see the black around the letters and white ghost outline that you see when you click on the animated gif below and jive displays the gif in his image popup window. Also 200 images in gif animation is a batch of images. If each image is completely different image than many unique pixels and especially you are probably too many colors to make a good animation Gif. GIF supports only 256 colors mapped.  If your image size is 800x800px all in all you 800x800x200px 128MP something like 380MB in Photoshop. The smallest 600 x 600 gif animated here is BW and transparent still gif file size is 5 MB.

  • Captive to capture images with the Nikon D7200?

    Is it possible to captive capture images with the Nikon D7200 in Lightroom cc? If this isn't the case, it will be possible in the future?

    Best regards

    Johan

    Hello

    Please upgrade to the latest version of Lightroom, and the question to tie with El Capitan will be resolved: keeping up-to-date for Lightroom

    Kind regards

    Tanuj

  • How to create a cursor image with text in motion.

    I tried to create a cursor image with text that slides with images. I use the jquery.cycle2 slider plugin that works very well for a slider I have on a different cursor on the same page. I'm not sure why it does not work. If someone could help me that would be great. The code is below:

    HTML:

    < div class = 'fluid wmud' id = 'wmud_img' data-cycle-fx = 'scrollLeft '.

    data-cycle-pause-on-hover = "true".

    data-cycle-speed '4000' = >

    < div class = "fluid wmud_img" >

    "< img src ="... /morris_construction/images/slider4.png"/ >

    < div class = "fluid wmud_text" >

    < h3 > Pro Active: < / h3 >

    < p > we have highly qualified staff and a thorough knowledge of the industry is thus able to add value by providing solutions to customers proactively; often even before that questions arise.                We are also very receptive to requests from the client and provide quick turnaround times, often to meet extremely tight deadlines. < /p >

    < / div >

    < / div >

    < div class = "fluid wmud_img" >

    "< img src ="... /morris_construction/images/slider5.png"/ >

    < div class = "fluid wmud_text" >

    < h3 > Pro Active: < / h3 >

    < p > we have highly qualified staff and a thorough knowledge of the industry is thus able to add value by providing solutions to customers proactively; often even before that questions arise.                We are also very receptive to requests from the client and provide quick turnaround times, often to meet extremely tight deadlines. < /p >

    < / div >

    < / div >

    < div class = "fluid wmud_img" >

    "< img src ="... /morris_construction/images/slider6.png"/ >

    < div class = "fluid wmud_text" >

    < h3 > Pro Active: < / h3 >

    < p > we have highly qualified staff and a thorough knowledge of the industry is thus able to add value by providing solutions to customers proactively; often even before that questions arise.                We are also very receptive to requests from the client and provide quick turnaround times, often to meet extremely tight deadlines. < /p >

    < / div >

    < / div >

    < / div > <!--end of wmud-->

    JavaScript:

    " < script src =" http://malsup.github.com/jQuery.cycle2.js "> < / script > .

    < script type = "text/javascript" >

    {$(function()}

    $('#wmud_img').cycle ({}

    FX: 'scrollLeft ',.

    });

    });

    < /script >

    Try these demos:

    Cycle2 overlays

    Cycle2 Caption2 Plugin

    Nancy O.

  • Library contains images with a 2/3 EV, 0EV bias bias.  How to separate them?

    I have a lot of images, taken with a 2/3 EV bias.  Mixed with a lot of images with 0 EV bias.  How can I identify one of them, so that I can handle a group only?  the Find command does not seem to locate different biases in camera.

    There are three ways that I know (all require plugins):

    1 Rob Cole metadata Extensions:

    Smart collection:

    2 John Ellis' AnyFilter

    3 Data Explorer. Jeffrey Friedl

    Internet search will reveal links in short order...

    Rob

Maybe you are looking for

  • Typed in the website of bad and sent me to a web page to download flash player. And told me to click on continue on safari.

    I was going to a Web page that I use usually, but I missed typed, and he sent me to a Web page to download flash player and command-Q to quit safari. I'm afraid it will download in my computer and it could uploaded a virus.

  • Root device

    Hello In some fetures (phone Cerberus protect apps) I'm asking 'possess the device rooted. Is there a way I can change my phone status root? Is this a legitimate status for the phone? I'd appreciate a brief explanation, if there is a risk of ny here.

  • (Redirected) thundebolt 3 or VGA/DVI/HDMI USB 3.0 adapter to

    Last week I got a new XPS13 (9350) who has only a USB 3.0 lightning 3 and two ports. What type of adapter will work to connect this device to a projector, screen VGA or DVI or HDMI? I've spent 40 minutes with and agent of Dell HYDSharma6-262211 which

  • BlackBerry Smartphones Blackberry in China using the local sim card service.

    I have a Bold 9700 (unlocked) that I would use in China. I hear it can be difficult if not impossible to get a pre paid sim with vocal abilities and data. Given just blackberry e-mail and messaging or does it include GPS and Internet? Thank you.

  • Cartoon / hand drawn filter possible?

    Hi motion graphics / illustration experts!I am working on a project where I want to create a simple cartoon style effect in a piece of footage and wondered how would be the best way to create something like this (reference): Watch Bleacher Report UK