Details
-
Bug
-
Resolution: Not an Issue
-
P2
-
None
-
8u40
-
Windows 7
Description
Run this sample test program :
"
import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.image.Image;
import javafx.scene.image.ImageView;
import javafx.scene.layout.GridPane;
import javafx.stage.Stage;
public class HugeMemoryTest extends Application {
@Override
public void start(Stage primaryStage) {
GridPane gridPane = new GridPane();
ImageView imageView = new ImageView(new Image("chart.png"));
gridPane.add(imageView, 0, 0);
Scene scen = new Scene(gridPane);
primaryStage.setScene(scen);
primaryStage.show();
}
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
launch(args);
}
}"
You will need this image http://i.imgur.com/N7yWVTV.png which is 5000x5000 but only weight 483ko.
Run the program and you will see that your JRE is using nearly 100Mb for displaying one single Image. The blame is on HeapByteBuffer.
I think it may be similar toRT-39386 but unsure. This is a serious issue.
"
import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.image.Image;
import javafx.scene.image.ImageView;
import javafx.scene.layout.GridPane;
import javafx.stage.Stage;
public class HugeMemoryTest extends Application {
@Override
public void start(Stage primaryStage) {
GridPane gridPane = new GridPane();
ImageView imageView = new ImageView(new Image("chart.png"));
gridPane.add(imageView, 0, 0);
Scene scen = new Scene(gridPane);
primaryStage.setScene(scen);
primaryStage.show();
}
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
launch(args);
}
}"
You will need this image http://i.imgur.com/N7yWVTV.png which is 5000x5000 but only weight 483ko.
Run the program and you will see that your JRE is using nearly 100Mb for displaying one single Image. The blame is on HeapByteBuffer.
I think it may be similar to