Resize the Image with the wheel causing exception 1502

Description:

I load an image inside a container of border and when I Zoom out, scroll bars disappear as expected. Now, when I resize the image to exceed the limits of the boarder container I get exception below. In my view, the exception is thrown when the scroll bars are reactivated but I could be wrong. Someone has seen this before

Exception:

Error: Error #1502: A script has executed for longer than the default timeout period of 15 seconds.
at spark.components.supportClasses::ScrollBarBase/get viewport()
at spark.components::VScrollBar/updateMaximumAndPageSize()[E:\dev\4.0.0\frameworks\projects\spark\src\spark\components\VScrollBar.as:123]
at spark.components::VScrollBar/http://www.adobe.com/2006/flex/mx/internal::viewportResizeHandler()[E:\dev\4.0.0\frameworks\projects\spark\src\spark\components\VScrollBar.as:390]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()[E:\dev\4.0.0\frameworks\projects\framework\src\mx\core\UIComponent.as:12266]
at mx.core::UIComponent/dispatchResizeEvent()[E:\dev\4.0.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9641]
at mx.core::UIComponent/setActualSize()[E:\dev\4.0.0\frameworks\projects\framework\src\mx\core\UIComponent.as:9172]
at spark.components::Group/setActualSize()[E:\dev\4.0.0\frameworks\projects\spark\src\spark\components\Group.as:891]
at mx.core::LayoutElementUIComponentUtils$/setLayoutBoundsSize()[E:\dev\4.0.0\frameworks\projects\framework\src\mx\core\LayoutElementUIComponentUtils.as:497]
at mx.core::UIComponent/setLayoutBoundsSize()[E:\dev\4.0.0\frameworks\projects\framework\src\mx\core\UIComponent.as:13069]
at spark.components.supportClasses::ScrollerLayout/updateDisplayList()[E:\dev\4.0.0\frameworks\projects\spark\src\spark\components\supportClasses\ScrollerLayout.as:546]
at spark.components.supportClasses::GroupBase/updateDisplayList()[E:\dev\4.0.0\frameworks\projects\spark\src\spark\components\supportClasses\GroupBase.as:1224]
at spark.components::Group/updateDisplayList()[E:\dev\4.0.0\frameworks\projects\spark\src\spark\components\Group.as:899]
at spark.skins::SparkSkin/updateDisplayList()[E:\dev\4.0.0\frameworks\projects\spark\src\spark\skins\SparkSkin.as:191]
at mx.core::UIComponent/validateDisplayList()[E:\dev\4.0.0\frameworks\projects\framework\src\mx\core\UIComponent.as:8531]
at mx.managers::LayoutManager/validateDisplayList()[E:\dev\4.0.0\frameworks\projects\framework\src\mx\managers\LayoutManager.as:663]
at mx.managers::LayoutManager/doPhasedInstantiation()[E:\dev\4.0.0\frameworks\projects\framework\src\mx\managers\LayoutManager.as:736]
at mx.managers::LayoutManager/doPhasedInstantiationCallback()[E:\dev\4.0.0\frameworks\projects\framework\src\mx\managers\LayoutManager.as:1072]
at flash.utils::Timer/_timerDispatch()
at flash.utils::Timer/tick()

MXML code:

<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
                  xmlns:s="library://ns.adobe.com/flex/spark" 
                  xmlns:mx="library://ns.adobe.com/flex/mx"
                  xmlns:ns1="com.adobe.wheelerstreet.fig.panzoom.*"
                  pageTitle="FileNet Flex Viewer"
                  minWidth="955" 
                  minHeight="600" 
                  creationComplete="init()">
     <fx:Style>
          @namespace s "library://ns.adobe.com/flex/spark";
          @namespace mx "library://ns.adobe.com/flex/mx";
          /*
          s|Application {
          backgroundGradientColors: #000000, #222222;
          }          
          */
          s|Button#zoomInButton {          
               skinClass: ClassReference("skins.ZoomIn");
          }
          
          s|Button#zoomOutButton {          
               skinClass: ClassReference("skins.ZoomOut");
          }
          
          s|Button#fitToWindowButton {          
               skinClass: ClassReference("skins.FitToWindow");
          }
          
          s|Button#fitToWidthButton {          
               skinClass: ClassReference("skins.FitToWidth");
          }
          
          s|Button#fitToHeightButton {          
               skinClass: ClassReference("skins.FitToHeight");
          }
          
          s|Button#rotateRightButton {          
               skinClass: ClassReference("skins.RotateRight");
          }
          
          s|Button#rotateLeftButton {          
               skinClass: ClassReference("skins.RotateLeft");
          }
          
          s|ToggleButton#rubberBandZoomButton {          
               skinClass: ClassReference("skins.RubberBand");
          }
          
          
          
     </fx:Style>
     
     <fx:Declarations>
          <!-- Place non-visual elements (e.g., services, value objects) here 
          <s:Rotate id="rotator" angleFrom="{angle-90}" angleTo="{angle}" target="{img}"/>
          -->
          <s:Resize id="resize" target="{img}"/>
          <s:Rotate id="rotate" target="{img}"/>
          <!--<s:Resize id="contract" target="{img}"/> -->
     </fx:Declarations>
     
     
     <fx:Script>
          <![CDATA[
               
               import flash.net.navigateToURL;
               
               import mx.controls.Alert;
               
               [Bindable]
               private var _imageURL:String = "images/earth-map_small.jpg";
               
               [Bindable]
               public var angle:Number = 0;
                    
               [Bindable]
               private var borderHeight:Number;
               
               [Bindable]
               private var borderWidth:Number;
               
               private var effectDuration:Number = 250;
               private var defaultRotation:Number = 90;
               
               private var profits:Array;
               private var dragStart:Point;
               private var dragEnd:Point;
               private var zoomingEnabled:Boolean;
               
               public var originalHeight:Number;
               public var originalWidth:Number;
               
               public function init():void{
                    originalHeight = img.height;
                    originalWidth = img.width;
                    borderHeight = borderContainer.height - 5;
                    borderWidth = borderContainer.width - 5;
               }
               
               
               public function fitToWindow():void{
                    resize.end();
                    resize.duration = effectDuration;
                    
                    if(img.rotation == defaultRotation || img.rotation == -defaultRotation){     
                         resize.heightTo = borderWidth;
                         resize.widthTo = borderHeight;
                    }
                    else{
                         resize.heightTo = borderHeight;
                         resize.widthTo = borderWidth;
                    }
                    
                    resize.play();
               }
               
               public function fitToWidth():void{
                    resize.end();
                    resize.duration = effectDuration;
                    
                    if(img.rotation == defaultRotation || img.rotation == -defaultRotation){
                         resize.heightTo = borderWidth;
                    }
                    else{
                         resize.widthTo = borderWidth;
                    }
                    
                    resize.play();
               }
               
               public function fitToHeight():void{
                    resize.end();
                    resize.duration = effectDuration;
                    
                    if(img.rotation == defaultRotation || img.rotation == -defaultRotation){
                         resize.widthTo = borderHeight;
                    }
                    else{
                         resize.heightTo = borderHeight;
                    }
                    
                    resize.play();
               }
               
               public function zoomIn():void{
                    resize.end();
                    resize.duration = effectDuration;
                    resize.heightTo = img.height*2;
                    resize.widthTo = img.width*2;
                    resize.play();
                    
               }
               
               public function zoomOut():void{
                    resize.end();
                    resize.duration = effectDuration;
                    resize.heightTo = img.height/2;
                    resize.widthTo = img.width/2;
                    resize.play();
               }
               
               public function rotateRight():void{
                    rotate.end();
                    rotate.duration = effectDuration-200;
                    rotate.angleFrom = angle;
                    rotate.angleTo = (angle += defaultRotation);
                    rotate.play();
               }
               
               public function rotateLeft():void{                    
                    rotate.end();
                    rotate.duration = effectDuration-200;
                    rotate.angleFrom = angle;
                    rotate.angleTo = (angle -= defaultRotation);
                    rotate.play();
               }
               

               private function initRectangle(e:MouseEvent):void{
                    
               }
               
               private function showShowRectangle(e:MouseEvent):void{

               }
               
               private function clearRectangle(e:MouseEvent):void{

               }
               
               
          ]]>
     </fx:Script>
     
     <s:Panel
          id="mainPanel"
          left="5" 
          right="5" 
          top="5" 
          bottom="5" 
          title="FileNet Flex Viewer" 
          fontWeight="bold">
          
          
          <mx:ApplicationControlBar dock="true" top="0" left="0" right="0">
               <s:Button 
                    id="zoomInButton"
                    toolTip="Zoom In"
                    click="{zoomIn();}"
                    />
               <s:Button 
                    id="zoomOutButton"
                    toolTip="Zoom Out"
                    click="{zoomOut();}"
                    />
               <s:Button 
                    id="fitToWindowButton"
                    toolTip="Fit To Window"
                    click="{fitToWindow();}"
                    />
               <s:Button 
                    id="fitToWidthButton"
                    toolTip="Fit To Width"
                    click="{fitToWidth();}"
                    />
               <s:Button 
                    id="fitToHeightButton"
                    toolTip="Fit To Height"
                    click="{fitToHeight();}"
                    />
               <s:Button 
                    id="rotateRightButton"
                    toolTip="Rotate Right"
                    click="{rotateRight();}"
                    />
               <s:Button 
                    id="rotateLeftButton"
                    toolTip="Rotate Left"
                    click="{rotateLeft();}"
                    />
               <!--<s:ToggleButton 
                    id="rubberBandZoomButton"
                    toolTip="Rubber Band Zoom"
                    click="{}"
                    />
               -->
          </mx:ApplicationControlBar>
          
          <s:BorderContainer 
               id="borderContainer"
               right="5" 
               left="5" 
               top="40" 
               bottom="5">
               
               <s:Scroller
                    width="100%"
                    height="100%">
                    <s:Group>
                         <mx:Image 
                              id="img"
                              maintainAspectRatio="false"
                              maintainProjectionCenter="true"
                              source="@Embed('images/earth-map_small.jpg')"
                              verticalCenter="0"
                              horizontalCenter="0" 
                              horizontalAlign="center" 
                              verticalAlign="middle"/>
                    </s:Group>
               </s:Scroller>
          </s:BorderContainer>
     </s:Panel>
     
</s:Application>

 

I think that this smaller version shows the consisently (attached JPG) question:

http://ns.Adobe.com/MXML/2009.
xmlns:s = "library://ns.adobe.com/flex/spark".
xmlns:MX = "library://ns.adobe.com/flex/mx" >
   
   
        public function fitToWindow (): void {}
IMG. Height = borderContainer.height;
IMG. Width = borderContainer.width;
}
]]>
   

   
   
       
   

   
   
       
           
               
horizontalCenter = red '0' = '0' / >
           

       

   

   

Looks like the interaction of Red/horizontalCenter with the add/remove scroll bars causes a loop.  Can you please fill a bug report and post the link here?  (Or let me know if you prefer that I have put it).

The workarounds are:

1. in the fitToWindow() method to subtract enough pixels to consider both sides of the border, for example:

public function fitToWindow (): void {}
IMG. Height = borderContainer.height - 2;
IMG. Width = borderContainer.width - 2;
}

2. always keep the scroll bars displayed, for example:

3. instead of use BorderContainer use SkinnableContainer/group and draw the border outside the container, for example:


       
           
               
           

       

  
       
           
               
                   
horizontalCenter = red '0' = '0' / >
               

           

       

   

Let me know if these solutions of workaround for the case also reduces work for your application.

Tags: Flex

Similar Questions

  • How one is resized an 'image' with the cutting tool?

    I would like to resize an 'image' of a part of one of my accounts on the Internet I did using the cutting tool.  I was able to do this with Windows 7 and have been unable to find a way to do it or to find a solution through research on the Internet.  Maybe the problem is the program that opens the image in full screen only.  Needless to say that Windows 8 is all new to me - a few weeks of usage and I know I have a LOT to learn!  And... I hope I picked the right area for this help!  Your help is greatly appreciated.  Thank you!

    Hello

    I'm not clear - you try to do this in Windows 7 or Windows 8?

    Whatever it is, the basic procedure is:

    1. open the cutting tool.

    2. create the new chiseled image.

    3. Select Save as.

    4. give it a name and select the image type from the menu drop down.

    (PNG is generally preferable for screenshots)

    5. save it to the desired location on your hard drive.

    6. open in an app - integrated image editing paint will do.

    7. open the image that you saved earlier.

    8. click on resize (in painting its on the home tab, in the upper part).

    9 select whether you want to resize a percentage or a non-specific pixels & enter the settings.

    10. Select maintain proportions if you want to keep the ratio width even height.

    11. click on OK.

    If you use Windows 8 and when you double click on an image it goes to an application full screen then it looks like this file type can be associated with the application of the user interface modern Photos. Please see:

    http://Windows.Microsoft.com/en-GB/Windows-8/choose-Programs-Windows-uses-default

    For more information about how to change default programs in Windows 8.

  • Tables of Images with different heights, causing the removal of Menu

    OK, I posted this issue in the Council of LabVIEW before I realized that it was associated with Vision.  I made some progress, narrowing of the cause, so I thought it would be best to start a new post here.  Here is the original post:

    http://forums.NI.com/T5/LabVIEW/blank-pop-up-menus/m-p/3281194#M958610

    I'm running into a problem with all of my menus of LabVIEW to shutter when I create arrays of images where the heights do not match.  I have attached a vi I created to illustrate the issue.  In this document, I take a starting image and then extract subsets of it.  Because I don't know how much I'll have to check out until the moment of execution, I'm subpictures in an array.  What I've discovered, is that if the heights of subpictures don't match, I get a weird bug that causes all the menus in LabVIEW empty.  This includes all right click pop up in the façade, block, or Project Explorer diagram and drop-down selections as for enums and ring controls.  It also includes the file menu at the top of the window.

    Rerun this vi with subpictures equivalent height or no subpictures corrects hidden menus.  In addition, running IMAQ Dispose (with Boolean true of images) corrects the problem.

    I'm relatively new to the Vision, so I don't know if I'm missing something basic, but please let me know what you think.  Is there a better way to do this?

    Thank you

    Tim

    Hi Tim,.

    Thanks for reporting this problem. I have reported as a bug.

    I recommend using a Cluster or the KING for manual zoom toolbar. If you want to use an array, each element of the array must maintain the same amount of zoom. (Similar to each LED in a table must have the same color.)

    Sorry you came across this bug.

    Kind regards

  • Image with width percentage causes the offset Y

    When I put an image spark or mx on a percentage width, or 30%, the image is shifted location Y expected / desired. I have the Image in a HBox and I wait until it is flush with the top, but it seems to keep the same focus as the image full-size adding padding to the top.

    Any suggestions?

    Try to do the following:

    1. PaddingTop set to the myBox 0
    2. PaddingLeft set to the myBox 0

    Image of the spark isn't horizontalAlign and verticalAlign, if the steps above don't work, try with a mx Image and setting the horizontalAlign and verticalAlign on the image for the top and left.  Looking at your picture, it seems that it is the scale of the image horizontally and vertically and the pixels of the image of drawing in the vertical center of the Image.  You must specify the Image in order to align the top and left.

  • Resize the animation causes screen muck

    Hi all

    I have a problem when resizing to a published the two display animation in flash player 10 and also when adding an animation (swf) to an other captivate project. I applied all the latest patches to CP.

    When the flash player window resizing or resize animation inserted into my Captivate project I get interference (lines and dashes) screen displayed on the video.

    Here is the swf file, play in full screen. You can see that it is visually clean and clear.

    before.jpg

    Here is the swf file when the screen is smaller resized - you can see some added gray lines on the screen (in the point: on the ground and also around the items on the column Code ). Can someone tell me why this happens and how to fix and the video shows then clean and clear of all mud.

    after.jpg

    Thank you for any assistance.

    Kind regards

    Ben.

    Hello

    I'm not the development of the whole team, so this is just guessing. Captivate when published is totally bitmap and it's a pretty complex thing, video simulation with static slides, where not everything is changed when switching to another slide (to lower the file size). So I can imagine if you do not follow the rule of good practice for the treatment of bitmaps (as to avoid the scaling, choose the correct resolution...) artifacts will appear. But there are many more factors that CP must take in note (quality screen, browser, LMS...). Don't know about you, but I've been a photographer in the old analog days: take a picture with a small "disposable" camera and then try to turn this into a poster of good quality especially introduced artifacts as well. If you create a CP file in a non-proper resolution and tries to fix that later was a bit like that.

    Lilybiri

  • Database adapter &amp; mediator, called by the Service causes exception?

    Hello

    I have a database adapter, a mediator plugged in my composite.xml. In my BPMN process, I have a service that uses the Ombudsman as its implementation (?). He was able to build and deploy great of JDeveloper. But now that I am trying to execute the process of the workspace, I get this error:

    < 13 may 2014 12:58:13 PM PDT > < WARNING > < oracle.soa.adapter > < BEA-000000 > < JCABinding = > JCABinding = > search for DBTestComposer2:DBAdapter [DBAdapter_ptt::DBAdapterSelect(DBAdapterSelect_inputParameters,TestTableObpmCollection)] "ÉI/DB/cpdev_users" failure due to JNDI: unable to resolve ' ist. DB.cpdev_users'. Solved ' ist. DB' >

    < 13 may 2014 12:58:13 PM PDT > < error > < oracle.soa.adapter > < BEA-000000 > < JCABinding = > DBTestComposer2:DBAdapter [DBAdapter_ptt::DBAdapterSelect(DBAdapterSelect_inputParameters,TestTableObpmCollection)] could not invoke "DBAdapterSelect" against the "null" operation due to:

    LIAISON. JCA-12511

    JCA Binding Component connection problem.

    JCA Binding component is unable to create an outgoing connection of JCA (CCI).

    DBTestComposer2:DBAdapter [DBAdapter_ptt::DBAdapterSelect (DBAdapterSelect_inputParameters, TestTableObpmCollection)]: The JCA Binding component could not establish an outbound connection of JCA CCI due to the following problem: BINDING. JCA-12510

    Location of JCA resource adapter error.

    Cannot find the adapter in JCA resources via the element of the binding .jca file <-factory connections / >

    The Binding of JCA component is unable to startup of the resource adapter that is specified in the <-factory connections / > element: location = ' EI/DB/cpdev_users.

    The reason is most likely to be

    (1) the resource adapter RAR file has not been deployed successfully to the WebLogic application server or

    (2) the "< jndi name >" element in weblogic - ra.xml has not been defined in eis/DB/cpdev_users. In the latter case, you need to add a new factory of connections from WebLogic JCA (deploy a RAR).

    Please fix this and then restart the application server

    Please ensure that the JCA connection factory and dependent connection factories have been set up with a sufficient limit for maximum connections Please also make sure that the physical connection to the EIS server is available and the backend itself accepts connections.

    Could someone explain what this means? (Sorry, we're new on Oracle technology and a lot of this terminology). What resource adapter RAR files is this allusion? We would really appreciate solutions on how to fix or solve this problem!

    I think this might solve your problem: https://community.oracle.com/message/10235476#10235476

    Dan

  • BlackBerry 5 - image with text and the background transparent resizing

    Hey,.

    My application consists of a series of images stacked on each other. Some are transparent, some are not. I use images high resolution and resize them based on the width of the screen of the blackberry that runs the application.

    I'm having some trouble resizing of images with text on a transparent background. The resulting image is not of all anti-aliasing. This is the code I use to do:

    function scaleBitmap(Bitmap bmp){
    
    int rgb[] = new int[imageWidth * imageHeight];
    bmp.getARGB(rgb, 0, imageWidth, 0, 0, imageWidth, imageHeight);
    int rgb2[] = rescaleArray(rgb, imageWidth, imageHeight, width, height);
    scaledBmp.setARGB(rgb2, 0, width, 0, 0, width, height);
    
    return scaledBmp;
    }
    

    And here are the results from a group of images resized in photoshop:

    Is it possible that I could improve my resize code to give better results?

    Thanks in advance!

    I found a solution and it is on these forums all the time!

    http://supportforums.BlackBerry.com/T5/Java-development/solution-for-properly-resizing-transparent-b...

  • Acquisition of images with 3 USB cameras causing too many uses of the memory/cpu

    Dear experts,

    I'm trying to capture images with 3 cameras USB, located in 3 different positions. I have to initialize each cameras using USB list vi camera when switching between cameras. I realize that, by making this method causing too many uses of the memory/cpu and can cause CPU hang up. If I stop the program, the memory/cpu counter are down.

    Do you know how to reduce this problem.

    Thank you

    Hart


  • Resize the image with HTML5 Canvas - distortion

    Hi all

    I'm working on a Webworks app where I need to resize an image to upload it to a server. I use JQuery Mobile, the application should run on OS6 and upward. The user can use the camera or select a picture, the power off. The corresponding code is the following:

    function handleOpenedFile(fullPath, blobData) {
                    var image = new Image();
                    image.src=fullPath; //path to image
                    image.onload = function () {
                        var resized = resizeMe(image); // send it to canvas
                        //Do stuff with the DataURL returned from resizeMe()
                    };
            }
    
    function resizeMe(img) {
    
                var canvas = document.createElement('canvas');
                var width = Math.round(img.width / 2);
                var height = Math.round(img.height / 2);
                canvas.width = width;
                canvas.height = height;
                var ctx = canvas.getContext("2d");
                ctx.drawImage(img, 0, 0, width, height);
                return canvas.toDataURL("image/jpeg", 0.8);
            }
    

    I then use the Base64 in the DataURL for download on the server. The images are reduced, but they are truncated. Parts of the image are shifted autour and colors come out strange. It is not scaling in itself than the mess to the top of the picture it comes out garbled if you draw on the canvas without any scaling.

    Does anyone have an idea how to solve this problem or have another suggestion to resize an image for download?

    I managed to solve the problem of resizing for anyone who takes place also in this. Replacement of

    return canvas.toDataURL("image/jpeg", 0.8);
    

    with

    return canvas.toDataURL();
    

    solved the problem with the strange visual artifacts. Returns a picture of resized without any strangeness.

  • resize the image in a div with css

    Hi I have a slideshow and I load image dynamically with this code when I click on the thumb

    ($(sym.lookupSelector ("image1container")) .css ("background-image', ' url(images/ALBUM_01/album1_1.jpg)');

    All good, but what an opportunity of css, I use to Center and resize the image in a div to 100% height and 100% width of the div?

    It's my solution and it function

    I have attached the external stylesheet in compositionReady;

    $("_ _").appendTo ("#Stage");

    myStyle. CSS is subsequently

    @charset "utf-8";

    / * CSS document * /.

    HTML, body, #container {}

    height: 100%;

    Width: 100%;

    }

    IMG {}

    Max-width: 100%;

    height: auto;

    Width: auto\9; / * ie8 * /.

    }

    div {}

    background-repeat: repeat no.;

    background-size: 100% 100%;

    }

    on the edge of adobe in the rectangle that contains the image I put in class 'div '.

  • PS Newb needs help with resizing the image and print several sheet

    Hi, I am using PS CS3 to resize an image, I have so I can print to use as a map for a miniatures game.  I have no problem of scaling of the image to the appropriate size, but I can't understand how to print multiple image 8.5 x 11 sheets.  I thought I saw an option for such a procedure before, but maybe it was in another editing program.  If anyone has any ideas on how I could do this I would really appreciate hearing about them.  Thank you!

    Illustrator and InDesign are tiled printing, like CorelDraw. Photoshop, this title is not, but may be a few script for this. In your case, the simplest solution would be to save the file in PDF format and have Acrobat print a tiled (Page scaling of parameter in Acro print dialog box). You just need to make sure that your page corresponds to several pages. Unliek AI and ID, Acro chop only stuff based on standard paper sizes...

    Mylenium

  • Problem with the scale/resize the masks

    Win 7 64 bit, CS5.1

    This question relates to the updated scale/resize the layers with masks. I have a layer with a mask that only shows part of the image, so the majority of the mask is black. However, when I resize the layer (with linked mask), Photoshop changes the mask so that areas once black become white, except for the area around the part that has been hidden behind.

    Below are screenshots of the before - after a sample mask.

    Before:

    mask-before.jpg

    After:

    mask-after.jpg

    This example shows what happens to the mask using the Image > Image size of dialogue, which I would have assumed would fully respect the layout of the mask, but does not work. I also have the same problem when you use the transform tools. I also tried to change the permission of foreground/background colors to resize, just to see if it has auto-fill of the mask with white, but I saw no effect by changing or reversing the values.

    I am hoping there is a single place or a preference to prevent this behavior and respect for implementing page-fill masks when resizing. I appreciate any assistance.

    This is probably the reason why your seeing this behavior.

    If you add a layer mask > hide all, or invert the layer mask if you are using a layer mask > show all (even just by clicking on the button layer mask), just use Ctrl > I (Image > adjustments > invert) to reverse the layer mask.

    So you probably won't see this issue.

  • Right-click on the image with link problem after upgrade to 11.0

    After the upgrade, whenever I do a right-click on an image with a link, it opens the link rather than opening a menu drop-down. Any idea on what is causing this behavior?

    OK, think about it. Extension: Tab Utilities was the origin of the problem. Uninstall completely solved the problem, disable it does not solve it.

  • Resize the SD card image to fit screen

    Hello

    I've already learned how to read a bitmap file from the SD card with the following code:

    public Bitmap getBitmapFromFile(String file){
    
        Bitmap b = null;
            try{
                FileConnection oInputFileConnection = (FileConnection)Connector.open(file, Connector.READ);
                InputStream oInputStream = null;
    
                if(oInputFileConnection.exists())
                    oInputStream = oInputFileConnection.openInputStream();
    
                byte[] arrData = new byte[(int)oInputFileConnection.fileSize()];
                int nCode = oInputStream.read(arrData, 0, arrData.length);
                oInputStream.close();
                oInputFileConnection.close();
    
                 b = Bitmap.createBitmapFromBytes(arrData, 0, -1, 1);
            }catch(Exception e){
    
            }
        return b;
    }
    

    Now I want to format this bitmap to the size 480x360px. How can I do?

    I know what I can change with this

    b = Bitmap.createBitmapFromBytes(arrData, 0, -1, 1);
    

    but it is not so accurate.

    Can someone help me?

    just tried it out.

    public class Utils {
        public static Bitmap resizeBitmap(Bitmap image, int width, int height)
        {   
    
            //Need an array (for RGB, with the size of original image)
            //
            int rgb[] = new int[image.getWidth()*image.getHeight()];
    
            //Get the RGB array of image into "rgb"
            //
            image.getARGB(rgb, 0, image.getWidth(), 0, 0, image.getWidth(), image.getHeight());
    
            //Call to our function and obtain RGB2
            //
            int rgb2[] = rescaleArray(rgb, image.getWidth(), image.getHeight(), width, height);
    
            //Create an image with that RGB array
            //
            Bitmap temp2 = new Bitmap(width, height);
    
            temp2.setARGB(rgb2, 0, width, 0, 0, width, height);
    
            return temp2;
        }
        private static int[] rescaleArray(int[] ini, int x, int y, int x2, int y2)
        {
            int out[] = new int[x2*y2];
            for (int yy = 0; yy < y2; yy++)
            {
                int dy = yy * y / y2;
                for (int xx = 0; xx < x2; xx++)
                {
                    int dx = xx * x / x2;
                    out[(x2 * yy) + xx] = ini[(x * dy) + dx];
                }
            }
            return out;
        }
    }
    
  • How to resize the image

    Hi all

    IAM getting the image to the server I need to resize the images, iam specifying an area it should resize and display with out streatch the image; as in a browser if I reduce the size of the browser, then the size of the image decreases as the correspondent. What should I do for this in the mobile? for this whole method in blackbery?

    Thanks in advance.

    Hi all

    I solved the problem.

Maybe you are looking for

  • authentication failure loop

    After resetting my password, I get repeated windows come in Safari as follows: Connect to 1Password - password manager and secure your portfolio

  • Video display on a drive connected to an extreme AC?

    I have an extreme AC and would like to connect an external hard drive with a lot of videos of children. 1. is there a way to watch videos on the disc on an iPhone and iPad? 2. must long for a reader to wake up to the top and start the video playback

  • Equium A300D - Parralled/Dual Boot OS

    Hello. Yesterday I bought a laptop A300D and after setting up, I found her quite slow. For example, it will come with "Please wait" before show you the login screen when starting upwards. It takes at least just around 2-4minuets to allow you to open

  • the upgrade to windows 7

    Hello My computer is HP Compaq dc7700 Small Form Factor PC running Windows XP PRO. I would like to install windows 7.  I have 32 bit but I was wondering if this computer could be changed to 64-bit.

  • BlackBerry Smartphones 9900 No. trackpad, not applications

    Hi all almost 2 weeks ago, I got my Bold 9900. the first week, everything was fine. But now I can't use the Trackpad th, I usually, scrolling or navigate does not altougth I hear the sound of scrolling. the Blackberry App World I have installed 3 tim