• 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
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

image is not beeing drawn

 
Ranch Hand
Posts: 135
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

i add canvas into mine form and want to draw an image which i read from file. but when i run the program my canvas draws nothing.
this is how i read the image file:
if i do it like this than it draws me something

but if i change generatePixels function like this, i get empty window:

I can't understand what is wrong. I would be really glad if tou helped me
 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Do you have an old version of generatePixels() hanging around?
You call generatePixels(width, height) but the only method we can see declared is

Is this just an error in the typing or do you have another method in your component that matches that signature?
reply
    Bookmark Topic Watch Topic
  • New Topic