Porting Violet to Java
Just to let you know, it runs fine on my xubuntu with sun-java5-jre
and sun-java6-jre!
... but with icedtea-java7-jre I get errors.
take care
psor
and sun-java6-jre!
... but with icedtea-java7-jre I get errors.
Code: Select all
Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError: com/sun/image/codec/jpeg/ImageFormatException
at jViolet.jVioletMainView.<init>(jVioletMainView.java:30)
at jViolet.jVioletMainView$6.run(jVioletMainView.java:285)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:227)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:603)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:276)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:191)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:186)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:178)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:139)
Caused by: java.lang.ClassNotFoundException: com.sun.image.codec.jpeg.ImageFormatException
at java.net.URLClassLoader$1.run(URLClassLoader.java:221)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:209)
at java.lang.ClassLoader.loadClass(ClassLoader.java:324)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:269)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:337)
... 10 more
take care
psor
"The sleeper must awaken"
- ViennaLinux
- Posts: 191
- Joined: Thu Jul 26, 2007 9:26 am
- Location: Vienna/Austria
- Contact:
on the old beryl/compiz there was a problem showing java guis when using java version 6. (also jre6)
So if your gui is empty showing up or seems frozen its maybe a problem of beryl (dont know if this is still so). Try falling back to metacity or kwin or another windowmanager that is not using 3d stuff.
Tell me if that is fixed now in beryl/compiz or what it is called now *g* - compiz fusion?
So if your gui is empty showing up or seems frozen its maybe a problem of beryl (dont know if this is still so). Try falling back to metacity or kwin or another windowmanager that is not using 3d stuff.
Tell me if that is fixed now in beryl/compiz or what it is called now *g* - compiz fusion?
Core2duo e6600 @ 3.1GHz watercooled at default VCore ^^
vienna hit what i thought might be the problem.
MOST problems with comiz & java have been fixed, with the ONE exception of the netbeans installer very weird.
@psor, iceadtea 1.7 is alpha and incomplenet, and dosent even have all the swing code last time i checked, dont use it please or report bugs with it.
MOST problems with comiz & java have been fixed, with the ONE exception of the netbeans installer very weird.
@psor, iceadtea 1.7 is alpha and incomplenet, and dosent even have all the swing code last time i checked, dont use it please or report bugs with it.
Yes i know, my spelling sucks
additionally, every line is being added twice
EDIT: i've removed the OutputArea, so don't worry about doing it.
Code: Select all
Header loadedHeader loaded
Width: 600 Width: 600
Height: 450 Height: 450
Supersample Factor: 1 Supersample Factor: 1
Num samples: 299670000 Num samples: 299670000
Starting data read...Starting data read...
pixelData size: 3240000pixelData size: 3240000
...data read finished...data read finished
Display Image allocatedDisplay Image allocated
Starting ImageThread 1/1ImageThread 1 startedStarting ImageThread 1/1
ImageThread 1 started
Full processing necessaryFull processing necessary
Thread #1 calculating final luminanceThread #1 calculating final luminance
No supersample collapse necessaryNo supersample collapse necessary
ImageThread 1 completeImageThread 1 complete
Updating display image part 1/1...Updating display image part 1/1...
... update done... update done
Last edited by dougal2 on Fri Feb 01, 2008 7:35 am, edited 1 time in total.
ok, cool.
Have you an idea how we can access an instance of ImageThreadParams from the GUI?
Sorry if this seems a silly question, but I'm sure there's a good way to do it and several bad ways to do it, and I don't really have a clue.
The way I see it working is that when the user changes a parameter on the GUI the ImageThreadParams object is updated too, then when an ImageThread is started, the params are passed to it.
How is best to set this up?
Also, ignore the edit on my last post. I'll do a fresh checkout after your updates.
Have you an idea how we can access an instance of ImageThreadParams from the GUI?
Sorry if this seems a silly question, but I'm sure there's a good way to do it and several bad ways to do it, and I don't really have a clue.
The way I see it working is that when the user changes a parameter on the GUI the ImageThreadParams object is updated too, then when an ImageThread is started, the params are passed to it.
How is best to set this up?
Also, ignore the edit on my last post. I'll do a fresh checkout after your updates.
i just finished fixing the things i said i would, but not commiting. what i think would be a good way to do it is create a model classes for the GUI comonents.
OR the other way you can do this, which reqires you pay attention to what your calling wear, is the pass the GUI as an argument.
new ImageThread(this);
im going to look at writing modles for the GUI comonents as i like the first way later tonight / tomarow.
ALSO, the other way you can do all this, is to get the values from teh GUI and create a new thread object to do a specific task every time the user clicks "apply"
Revsion 33
fixed all that stuff you mentiond, no longer rights to a file
added an a option to hide/display the output
minor rework of the MainGUI
OR the other way you can do this, which reqires you pay attention to what your calling wear, is the pass the GUI as an argument.
new ImageThread(this);
im going to look at writing modles for the GUI comonents as i like the first way later tonight / tomarow.
ALSO, the other way you can do all this, is to get the values from teh GUI and create a new thread object to do a specific task every time the user clicks "apply"
Revsion 33
fixed all that stuff you mentiond, no longer rights to a file
added an a option to hide/display the output
minor rework of the MainGUI
Yes i know, my spelling sucks
REVISION 34
I've started to hook up the GUI, but I'm not convinced that I'm doing it in the best way, so I thought I'd do only 1 set of parameters (the reinhard parameters) and get your opinions on the implementation.
I have a feeling that the way the parameters are handled needs to be somewhat refactored away from the C++ style of code to make it more Java-like, but I don't really know how.
At the minute we have an ImageThreadParams class that contains other classes and values which are used by the ImageThread for processing.
Until now, the only instance of ImageThreadParameters was in ImageThread itself.
I have move the instanciation up to jVioletApp, so that the GUI components can call back to it via
jVioletMainView also contains a reference to this instance and passes it to ImageThread when the threads are launched.
To me, this code looks and feels a little clunky, despite the fact that it works.
How would you do it?
I've started to hook up the GUI, but I'm not convinced that I'm doing it in the best way, so I thought I'd do only 1 set of parameters (the reinhard parameters) and get your opinions on the implementation.
I have a feeling that the way the parameters are handled needs to be somewhat refactored away from the C++ style of code to make it more Java-like, but I don't really know how.
At the minute we have an ImageThreadParams class that contains other classes and values which are used by the ImageThread for processing.
Until now, the only instance of ImageThreadParameters was in ImageThread itself.
I have move the instanciation up to jVioletApp, so that the GUI components can call back to it via
Code: Select all
org.jdesktop.application.Application.getInstance(jViolet.jVioletApp.class).{instance of ImageThreadParams}
To me, this code looks and feels a little clunky, despite the fact that it works.
How would you do it?
Who is online
Users browsing this forum: No registered users and 6 guests