• 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:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Drawing non-standard shapes in MIDP 2.0

 
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can anyone guide me (resources, classes, methods etc..) as to how I would go about drawing shapes on a canvas in midp2.0?

for example I would like to draw the outlines of a vase, a bowl, a bottle etc.. that sort of thing.

Is this possible, or would I have to start using sprites/images..?

The reason I don't want to use images is that I would like the user (thru UI interaction) to influence the shapes by pressing buttons/tapping the shape with a stylus etc..

Any help appreciated,
cheers,
Mark
 
Mark Greene
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
No one..?
 
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

Check out javax.microedition.lcdui.Graphics class. In this class are all the drawing methods provided in MIDP. It is not going to be very easy to draw arbitrary shapes, because there aren't drawing methods for curves, only arcs.

There is a third party library: TinyLine 2D that allows drawing arbirtrary curves.
It is free currently, but it is not open source (it may not stay free).

Yuri
[ February 11, 2005: Message edited by: Yuri Magrisso ]
 
reply
    Bookmark Topic Watch Topic
  • New Topic