Welcome Guest! You need to login or register to make posts.

Notification

Icon
Error

2 Pages12>
Options
Go to last post Go to first unread
ChingYen  
#1 Posted : Tuesday, December 21, 2010 7:45:27 AM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Hi,

We are looking into this http://demo.aurigma.com/PhotoEditor/
Wondering, how can we hide the 'control panel' on top? And also, is that possible to change the Crop display?

We would like to have 2 layers of crop marking..
Please have a look on the attached photo for illustration


As we would like to show the customer about the safezone.

Please advise. Thanks.
ChingYen attached the following image(s):
DoubleLayer.jpg
Dmitry.Obukhov  
#2 Posted : Thursday, December 23, 2010 12:22:05 AM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello Ching-Yen,

Thanks for taking interest in our software.
  1. Quote:
    Wondering, how can we hide the 'control panel' on top?

    Please open PhotoEditorSample.ascx of Photo Editor source project, find class="PhotoEditorSampleControlPane, and just comment the whole div element which contains this class. You are able to implement the code allowing to hide/show this panel by demand.
  2. Quote:
    And also, is that possible to change the Crop display?

    Unfortunately, it is not possible.
  3. Quote:
    the user did a selection on the crop area, but, didn't click on the "crop", so, when the user click on the other tab like "effects", the crop area will be gone.

    This behavior is set by design. User should click “Apply crop” button before switching the tabs.
  4. Quote:
    We found that when the user selection were in low res, the color of the crop area will change to other color like red or yellow. Just wondering, is there anyway we can show in Text as well??

    Sure, you can set some warning message. You need to open \PhotoEditor\Scripts\Effects\CropEffect.js file, and add your code in this method:
    Code:
    
    _onRectangleChanging: function(evt) {
      /// <private />
      var controller = $find(this._controllerId);
      var qm = $find(controller.get_qualityMeterId());
      var rr = $find(controller.get_rectangleRubberbandId());
      if (rr) {
       var rect = rr.get_rectangle();
       var resolution = rect.width * controller.get_resizeRatio();
       resolution /= (this._orientation == "Portrait") ?
        this._cropFormats[this._selectedSize].width :
        this._cropFormats[this._selectedSize].height;
       if (qm) {
        qm.set_resolution(resolution);
        var maxResolution = qm.get_maximumResolution();
        
        if (resolution < maxResolution / 3) {
         rr.set_outlineColor("#FF0000");
         /* Add code to show warning message that the crop resolution is too low */
        }
        else if (resolution < maxResolution * 2 / 3) {
         rr.set_outlineColor("#DBDB00");
        }
        else {
         rr.set_outlineColor("#24B600");
        }
       }
      }
     },
The source code of Photo Editor component is available completely to edit it according to your requirements.

Please feel free to let me know if you have any questions.
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
ChingYen  
#3 Posted : Thursday, December 23, 2010 8:38:13 AM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Thanks for the reply.

Here is another question. We found that whenever user click on the "crop", it will actually just select an area in the image and highlight them with the crop ratio. Just wondering, can it be always Center Crop?

Example: if the photo is 3 x 4
and the using select 1 x 1 ratio, then the preselect region will be 3 x 3 (means it will select full width, and center 3" of the height)

So, if the photo is 3 x 3, then the selected area will be the fill image.
Dmitry.Obukhov  
#4 Posted : Friday, December 24, 2010 6:12:33 AM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello Ching-Yen,

Please explain it more detailed. It would be great is send some image to illustrate your explanation.
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
ChingYen  
#5 Posted : Saturday, December 25, 2010 7:33:48 PM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Hi,

Please have a look on the attachment. The "Current.jpg" is when I upload a photo in landscape, and I click on "12x12" crop, it will generate a crop zone @ the center of the photo. But, what we need is "New.jpg" which it will generate a crop zone which will max out the crop area (Center crop of the photo)
ChingYen attached the following image(s):
Current.jpg
New.jpg
Dmitry.Obukhov  
#6 Posted : Monday, December 27, 2010 11:12:58 PM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello,

You need to comment, or just remove these lines:
Code:
 //var w = newRect[2] / 8;
//var h = newRect[3] / 8;
//newRect[2] -= w * 2;
//newRect[3] -= h * 2;

in the \PhotoEditor\Scripts\Effects\CropEffect.js file.
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
thanks 1 user thanked Dmitry.Obukhov for this useful post.
ChingYen on 12/28/2010(UTC)
ChingYen  
#7 Posted : Tuesday, December 28, 2010 8:29:58 PM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Is that possible that we get the crop area (the x, y, width, and height) value while we click on the "show full image button".

And also which crop size (button) has been choose. Thanks.
Dmitry.Obukhov  
#8 Posted : Wednesday, December 29, 2010 3:24:59 AM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello Ching-Yen,

Could you please explain what you want to get eventually?
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
ChingYen  
#9 Posted : Wednesday, December 29, 2010 10:59:47 AM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Dmitry.Obukhov wrote:
Hello Ching-Yen,

Could you please explain what you want to get eventually?


Hi,

When the user click on the "show full image", We would like to know which "crop size" is being selected, and will auto apply the "apply crop".

In other words, the user can just select the crop size, and click on the "Show full image" to get the cropped image. (Skip the step for pressing the apply crop button). If there is no "Crop Size" being selected, then, it will not process anything but prompt using must select a crop size.

Thanks.
Dmitry.Obukhov  
#10 Posted : Thursday, December 30, 2010 4:10:04 AM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello Ching-Yen,

Thanks for the explanation.

To implement this functionality you should call _onApplyButtonClick() method when click “Show full image” button. Here is the code snippet how to do it:
Code:

<% = ClientID.ToString() %>_stopWarning = function()
  {
//Crop the image
  $find($find("PhotoEditorSample1_PhotoEditorController1").getEffectIdByType('Aurigma.PhotoEditor.Effects.CropEffect'))._onApplyButtonClick();
   var photoEditor = $find(<% = "\"" + PhotoEditorController1.ClientID + "\"" %>);
   photoEditor.set_showExitMessage(false);
   return true;
  }

This handler is located in the PhotoEditor\PhotoEditor\ PhotoEditorSample.ascx file.
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
ChingYen  
#11 Posted : Friday, December 31, 2010 5:31:25 PM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Thanks. But, how we know which crop size is being chosen? We need to know the value from code behind.. (As the crop in the image is just a ration, but not the actual size in inch).
Dmitry.Obukhov  
#12 Posted : Monday, January 3, 2011 3:44:44 AM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello Ching-Yen,

_onApplyButtonClick (\PhotoEditor\Scripts\Effects\CropEffect.js) includes an array with crop rectangle size. Please check it.
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
ChingYen  
#13 Posted : Sunday, January 9, 2011 10:31:35 PM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Dmitry.Obukhov wrote:
Hello Ching-Yen,

_onApplyButtonClick (\PhotoEditor\Scripts\Effects\CropEffect.js) includes an array with crop rectangle size. Please check it.



Hi, do you mean by this? this._oldRect = new Array(rect.x, rect.y, rect.width, rect.height);

This will only tell the size to be cropped on the image, but, not telling us which button did the user selected (Example: 12" x 12", 4" x 6") so that we can print to the correct size.

Please advise.
Dmitry.Obukhov  
#14 Posted : Monday, January 10, 2011 1:56:16 AM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello Ching-Yen,

You are able to get this crop size in inches. You just need to divide width and height by image resolution, e.g.:
Code:
 alert(Math.round(rect.height / bv._bitmap$verticalResolution) + " " + Math.round(rect.width / bv._bitmap$horizontalResolution));
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
ChingYen  
#15 Posted : Monday, January 10, 2011 2:49:14 AM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Dmitry.Obukhov wrote:
Hello Ching-Yen,

You are able to get this crop size in inches. You just need to divide width and height by image resolution, e.g.:
Code:
 alert(Math.round(rect.height / bv._bitmap$verticalResolution) + " " + Math.round(rect.width / bv._bitmap$horizontalResolution));


Hi, This will only show the "image size in inch", but not the user selected size. Or should i called them "format" to avoid confusion?

Let say, the user uploaded the photo which is 3" x 6 ", and select a format of "12 x 12", this will lead the user max to have a physical photo of 3" x 3". So, during our print out, we need to manually enlarge it, please correct me if I am wrong on this part. So, we need to know the user is select the format of "12 x 12" or 6" x 6".

In short, we would like to know which is the last selected "format (Crop size) button".

Please advise.
Dmitry.Obukhov  
#16 Posted : Wednesday, January 12, 2011 4:54:18 AM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello Ching-Yen,

Sorry for the delay.

You can get the number of selected button in the _onSizeButtonClick() method:
Code:

if (this._selectedSize == -1) {
            this._cropFormats[index].button.className = "SimpleEffectSelectButton";
            this._selectedSize = index;
            alert(this._selectedSize);
            this._update();
        }
        else {
            if (this._selectedSize == index) {
                this._cropFormats[index].button.className = "SimpleEffectButton";
                this._selectedSize = -1;
                alert(this._selectedSize);
                this._update();
            }
            else {
                this._cropFormats[index].button.className = "SimpleEffectSelectButton";
                this._cropFormats[this._selectedSize].button.className = "SimpleEffectButton";
                this._selectedSize = index;
                alert(this._selectedSize);
                this._updateRubberband();
}

This method is located in the \PhotoEditor\Scripts\Effects\CropEffect.js file.
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
ChingYen  
#17 Posted : Friday, January 14, 2011 1:22:30 AM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Thanks for all the support have been given. Perhaps this will be the last 2 question we having..

Let say, we do store in the session that what format customer has been chose, and know the x, y, width and high of the crop area.

How can we programmatically load the crop area while the page load?

Please advise.
Dmitry.Obukhov  
#18 Posted : Monday, January 17, 2011 3:40:10 AM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello Ching-Yen,

You need to add these lines:
Code:

//Select size of arbitrary crop size
$find($find("PhotoEditorSample1_PhotoEditorController1").getEffectIdByType('Aurigma.PhotoEditor.Effects.CropEffect'))._selectedSize = 3 ;
//Update rubberband  
$find($find("PhotoEditorSample1_PhotoEditorController1").getEffectIdByType('Aurigma.PhotoEditor.Effects.CropEffect'))._update();

in the beginning of Sys.Application.add_load(function(e, t) method, which is located in the PhotoEditor\PhotoEditorSample.ascx file.

Let me know, if you have any questions.
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
ChingYen  
#19 Posted : Monday, January 17, 2011 9:40:49 PM(UTC)
ChingYen

Rank: Advanced Member

Groups: Member
Joined: 3/3/2008(UTC)
Posts: 185

Thanks: 8 times
Dmitry.Obukhov wrote:
Hello Ching-Yen,

You need to add these lines:
Code:

//Select size of arbitrary crop size
$find($find("PhotoEditorSample1_PhotoEditorController1").getEffectIdByType('Aurigma.PhotoEditor.Effects.CropEffect'))._selectedSize = 3 ;
//Update rubberband  
$find($find("PhotoEditorSample1_PhotoEditorController1").getEffectIdByType('Aurigma.PhotoEditor.Effects.CropEffect'))._update();

in the beginning of Sys.Application.add_load(function(e, t) method, which is located in the PhotoEditor\PhotoEditorSample.ascx file.

Let me know, if you have any questions.


Hi, this will only select the crop area by center crop, but, what if the user did shifted the crop area? We need to restore the x,y, width and height, plus the orientation of cropping.

Please advise....

The basic idea we want to archive is, when, the user navigate to another page, and click on the "back", it will see what they did previously.
Dmitry.Obukhov  
#20 Posted : Thursday, January 20, 2011 12:11:43 AM(UTC)
Dmitry.Obukhov

Rank: Advanced Member

Groups: Administration
Joined: 5/29/2010(UTC)
Posts: 1,310

Thanks: 8 times
Was thanked: 111 time(s) in 111 post(s)
Hello Ching-Yen,

Sorry for the long delay.

I spent many time to approach necessary effect. Unfortunately, it is not possible to implement this functionality.
Best regards,
Dmitry Obukhov
Technical Support. Aurigma, Inc.
Users browsing this topic
Similar Topics
Photo Editor does not work on IE 9? (Discussions – Graphics Mill)
by ChingYen 6/19/2011 6:10:45 PM(UTC)
Skin Photo Editor (Discussions – Graphics Mill)
by ChingYen 1/25/2011 3:23:20 AM(UTC)
Photo Editor vb.net version? (Discussions – Graphics Mill)
by ssjdoob 8/1/2010 9:59:13 PM(UTC)
INFO: Photo Editor Community Project (Archive - Graphics Mill)
by Dmitry 6/9/2010 7:11:58 PM(UTC)
Photo Editor with Image Uploader (multiple image versions) (Discussions – Graphics Mill)
by Ken 6/7/2010 11:28:16 AM(UTC)
Photo Editor - IFrame - IE (Access is Denied) (Discussions – Graphics Mill)
by sajjarapu 4/15/2009 7:53:05 AM(UTC)
Photo Editor - Apply Crop Behavior (Discussions – Graphics Mill)
by sajjarapu 2/27/2009 12:13:18 AM(UTC)
Photo Editor on LightBox (Discussions – Graphics Mill)
by Harish Sindhey 3/11/2008 6:02:14 PM(UTC)
Error on Photo Editor (Discussions – Graphics Mill)
by ktratt 11/28/2007 2:37:33 PM(UTC)
Photo Editor 2.0 Issue (Discussions – Graphics Mill)
by ktratt 5/18/2007 4:48:12 AM(UTC)
Photo Editor 2.0 installation issues- Sample Application (Discussions – Graphics Mill)
by ktratt 5/18/2007 3:59:52 AM(UTC)
How to download trial version of photo Editor (Discussions – Graphics Mill)
by abdul_2008 1/2/2007 2:44:15 PM(UTC)
Photo Editor 2.0 Is Coming Soon (Discussions – Graphics Mill)
by Fedor 10/16/2006 4:29:29 PM(UTC)
photo editor configuration and deployment issues (Discussions – Graphics Mill)
by khurram 8/10/2006 4:39:44 PM(UTC)
photo editor configuration and deployment issues (Discussions – Graphics Mill)
by khurram 8/10/2006 4:36:50 PM(UTC)
2 Pages12>
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.