Our Feeds
Categories
Home
About
XploitZ
Vulnerability
Hacking
Shellcode
Buffer Overflow
Programming
CSS
C
CPP
Python
PHP
Java
HTML
Android
Video Tutorials
PlayStore*
Home
Java
JavaFX
Programming Language
Programming Languages Theory
JavaFX - Impress your lover [juZt 4 fUn] V.2.0
Sunday, 5 January 2014
Ajith KP
JavaFX - Impress your lover [juZt 4 fUn] V.2.0
Ajith KP
January 05, 2014
1 comment :
V.1.0 =>
http://terminalcoders.blogspot.in/2013/06/javafx-impress-your-lover-juzt-4-fun.html
I have added a simple animation to my previous post.
Source Code
/* * * * http://www.terminalcoders.blogspot.in * * Amsteck Arts & Science College * Ajith Kp [ajithkp560] * */ package javafx_11; import java.util.*; import javafx.animation.FillTransition; import javafx.animation.ParallelTransition; import javafx.animation.RotateTransition; import javafx.animation.ScaleTransition; import javafx.animation.Timeline; import javafx.animation.TranslateTransition; import javafx.application.*; import javafx.scene.*; import javafx.scene.effect.Reflection; import javafx.scene.paint.Color; import javafx.scene.text.*; import javafx.stage.*; import javafx.util.Duration; public class JavaFX_11 extends Application { Random rand = new Random(System.currentTimeMillis()); @Override public void start(Stage stage) { Text t = new Text("I Love You, By Ajith Kp"); Text[] bg = new Text[300]; int[] sign = {-1, 1}; t.setFont(Font.font("Comic Sans MS", 40)); Reflection r = new Reflection(); r.setFraction(0.90f); t.setFill(Color.rgb(0, 255, 0, .8)); t.setCache(true); t.setTranslateY(0);//160 t.setTranslateX(0);//55 t.setEffect(r); Group root=new Group(); Scene scene = new Scene(root, 800, 360, Color.BLACK); stage.setTitle("I Love You"); root.getChildren().add(t); for(int i=0; i<200; i++) { int x=rand.nextInt((int) scene.getWidth()); int y=rand.nextInt((int) scene.getHeight()); int si = rand.nextInt(2); int xx=rand.nextInt((x+20)); xx = xx*sign[si]; int yy=rand.nextInt((y+20)); yy = yy*sign[si]; int rro=rand.nextInt(360); int size=rand.nextInt(25); int rot=rand.nextInt(360); Font fnd=Font.font("SandSerif", size); bg[i] = new Text(x, y,"I Love You"); bg[i].setRotate(rot); int red=rand.nextInt(255); int green=rand.nextInt(255); int blue=rand.nextInt(255); bg[i].setFont(fnd); bg[i].setFill(Color.rgb(red, green, blue, 0.3)); TranslateTransition tra = new TranslateTransition(Duration.millis((10000))); tra.setToX(xx);//360 tra.setToY(yy);//160 FillTransition f = new FillTransition(Duration.millis(10000)); f.setToValue(Color.RED); RotateTransition rr = new RotateTransition(Duration.millis(10000)); rr.setToAngle(rro); ScaleTransition s = new ScaleTransition(Duration.millis(10000)); s.setToX(0.1); s.setToY(0.1); ParallelTransition pp = new ParallelTransition(bg[i],tra,f,rr,s); pp.setCycleCount(Timeline.INDEFINITE); pp.setAutoReverse(true); tra.setCycleCount(Timeline.INDEFINITE); tra.setAutoReverse(true); tra.play(); stage.setScene(scene); stage.show(); root.getChildren().add(bg[i]); } TranslateTransition tra = new TranslateTransition(Duration.millis((4000))); tra.setToX((int) scene.getWidth());//360 tra.setToY((int) scene.getHeight());//160 FillTransition f = new FillTransition(Duration.millis(4000)); f.setToValue(Color.RED); RotateTransition rr = new RotateTransition(Duration.millis(4000)); rr.setToAngle(360); ScaleTransition s = new ScaleTransition(Duration.millis(4000)); s.setToX(0.1); s.setToY(0.1); ParallelTransition pp = new ParallelTransition(t,tra,f,rr,s); pp.setCycleCount(Timeline.INDEFINITE); pp.setAutoReverse(true); tra.setCycleCount(Timeline.INDEFINITE); tra.setAutoReverse(true); tra.play(); stage.setScene(scene); stage.show(); } public static void main(String[] args) { launch(args); } }
Next
« Prev Post
Previous
Next Post »
1 comments :
Write comments
Drew N
AUTHOR
18 June 2022 at 13:45
delete
Hi thanks for posting this.
Reply
Popular Posts
Easiest way to convert RGB Color Image to Gray scale Image in Java
Hello GuyZ, I would like to share Java code to convert RGB images to Gray scale images. I have seen many Java codes which converts im...
Web Application Vulnerabilities: Dawn, Detection, Exploitation and Defence Slide Show
ABSTRACT Web applications are popular software application types in which the client runs the application stored in server in his/her we...
Histogram Equalization Algorithm and Implementation in Java
Histogram equalization is a technique used to enhance the contrast of image using the histogram of image. The histogram of image represents...
Fist GUI Program - FASM
I hope you have read the previous posts about FASM. Else please read it here: http://terminalcoders.blogspot.in/search/label...
Digital Camera Day or Night - Python Solution
"You need to construct a feature in a Digital Camera, which will auto-detect and suggest to the photographer whether the pi...
Beautiful Black-Green Theme for Hackers [GNOME/GTK/KALI LINUX]
If you like this theme download it from here: http://downloads.ziddu.com/download/24041123/HackerTheme.tar.gz.html ...
OpenGL: Line Drawing - DDA Algorithm
Hello GuYz, DDA algorithm is another popular line drawing algorithm. Source Code #include <gl/glut.h> #include <Wind...
Skin Detection Algorithm - Implementation in Java
Hi GuyZ,,, This is one of the partial solution of my Mini Project. This is an implementation of skin detection algorithm in Jav...
Buffer Overflow Tutorial: Socket Programs
Buffer Overflow is the vulnerability which make your system high risk. It allows unlimited access to the attacker, and allows inject shell...
Reverse IP Look up Tool in PHP
Reverse IP look up tool is very important for the hackers who need to hack servers and he can find vulnerable website from a lis...
..:: SUPPORT US ::..
Labels
Programming Language
Programming Languages Theory
Adv. Hacking
Hacking
Vulnerability
C++
ALOGORITHM
CPP
Java
C
Python
Linux
PHP
Shellcode
Buffer Overflow
JavaFX
x64
Android
Digital Image Processing
Graphics
Image Processing
Metasploit
OpenGL
AI
FASM
1 comments :
Write commentsHi thanks for posting this.
Reply