• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Ron McLeod
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Junilu Lacar
  • Rob Spoor
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Jesse Silverman
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Piet Souris
  • Frits Walraven

pivot point in java?

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
can anybody tell me what is the pivot point in java?
 
Bartender
Posts: 2236
63
IntelliJ IDE Firefox Browser Spring Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Pivot point is a term that is not related to Java in any way.

Do you have an assignment about writing a program related to pivot points?
 
Bartender
Posts: 10780
71
Hibernate Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Karan Jawa wrote:can anybody tell me what is the pivot point in java?


No. But I suspect that what you mean is a pivot point in a SORT (usually something like QuickSort), and that is the element about which you choose your "left" and "right" subsets.

And it's the same in every language.

HIH

Winston
 
Karan Jawa
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have got an assignment in javaFX in which we have to rotate the rectangle using transform method .
like,
Rectangle rectThree=new Rectangle(290,100,190,45);
rectThree.getTransforms().add(new Rotate(45,50,50));
 
Winston Gutkowski
Bartender
Posts: 10780
71
Hibernate Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Karan Jawa wrote:I have got an assignment in javaFX in which we have to rotate the rectangle using transform method .
like,
Rectangle rectThree=new Rectangle(290,100,190,45);
rectThree.getTransforms().add(new Rotate(45,50,50));


OK, so it looks like you want to know how to rotate a rectangle about a "pivot point" and return its primary corner vertices. Correct me if I'm wrong.

Again, this has nothing to do with Java, it's pure maths; and the answer (and methodology) will be the same in any language.

So perhaps the first question (and I'm not meaning to sound "superior" here) is: Do you know the maths involved?

Winston
 
Marshal
Posts: 74712
335
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Moving to JavaFX forum as too difficult a question for “Beginning”.
 
Campbell Ritchie
Marshal
Posts: 74712
335
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You should be able to work out what the three numbers in the transform arguments mean from the API documentation. Basically, you want to move the origin to the middle of your rectangle and then rotate around that point. I don't think it is called a pivot point, however.
 
Karan Jawa
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
okk i will figure it out,thanks by the way.
 
reply
    Bookmark Topic Watch Topic
  • New Topic