Java-Gaming.org Java4K winners: [ by our judges | by the community ]         
Featured games (67)
games approved by the League of Dukes
Games in Showcase (∞)
games submitted by our members



News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  Print  
  [SOLVED]Applet design Question  (Read 707 times)
0 Members and 1 Guest are viewing this topic.
Offline Cakey

Full Member
**

Posts: 127



« on: 2009-04-02 16:36:48 »

So, I am working on a new project(trying to keep busy).

I want to have text either appear on the screen as a HUD, but I don't really like that or I was thinking maybe I could do either of these two:

1. Find a way to pass the information to an external "text box" to the right of my GLCanvas(viewport), but I'm not exactly sure how to do that. I do know how to use Swing but I'm not sure exactly how to do it for applets, especially with a GLCanvas already on it.

or
 
2. Is it possible to pass information from an applet to say, PHP or HTML or JavaScript actively on a page? I wouldn't see how, or if it'd be worth it. I just figured I'd ask.

Just like exploring my options, and learning new things. The main reason why I don't want to do a HUD is just for FPS sake, and I want this to be a clean looking applet, not some Graphics class stretched around text HUD on-top of my already dodgey 3-D world.

Offline DzzD

JGO Kernel
*****

Posts: 2134
Medals: 16



« Reply #1 on: 2009-04-02 17:27:56 »

using opengl you should not have a lot of trouble with FPS for a simple HUD , no ? just disable zbuffer and draw it.

Quote
1. Find a way to pass the information to an external "text box" to the right of my GLCanvas(viewport), but I'm not exactly sure how to do that. I do know how to use Swing but I'm not sure exactly how to do it for applets, especially with a GLCanvas already on it.

and I am not really sure I undertand what you're trying to do Smiley


Quote
2. Is it possible to pass information from an applet to say, PHP or HTML or JavaScript actively on a page? I wouldn't see how, or if it'd be worth it. I just figured I'd ask.

look at liveconnect : JSObject or this.showDocument("javascript:alert('')")

Offline Cakey

Full Member
**

Posts: 127



« Reply #2 on: 2009-04-02 17:37:20 »

For number one I mean this.

<img src="http://i310.photobucket.com/albums/kk420/SmaerdsDreams/Untitled.gif">
(sorry I had a little too much fun drawing that picture lol)
Have a GLCanvas and GUI (panel?). Do all GUI's work for all systems if they have the proper JDK? I had a friend who on Mac OS 10(I think) couldn't run a reallllly simple applet I made that literally just had a button and a text box. But on all windows versions it worked fine.


The second one seems complicated, haha.

I'm just trying to save on not really FPS but CPU and visual memory, I want this to be a fast load, a smooth run, and an overall nice presentation.

Games published by our own members! Go get 'em!
Offline DzzD

JGO Kernel
*****

Posts: 2134
Medals: 16



« Reply #3 on: 2009-04-02 17:45:18 »

good draw but you wont make a carrer in design Wink

so hum.. I can just say that "yes you can" Smiley

Offline DzzD

JGO Kernel
*****

Posts: 2134
Medals: 16



« Reply #4 on: 2009-04-02 17:46:17 »

you just have to size your GLCanvas and your gui component to half of the with , no ?

Offline Cakey

Full Member
**

Posts: 127



« Reply #5 on: 2009-04-02 17:48:18 »

Hmmmmm, lemme look to see how I implemented the canvas then hopefully I'll get back to you with some proper news haha.

Oh dang you just broke my heart, coulda swore I just drew the next van gogh  Smiley.

Offline Cakey

Full Member
**

Posts: 127



« Reply #6 on: 2009-04-02 18:06:44 »

Got it woo hoo! Thanks

Pages: [1]
  Print  
 
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.089 seconds with 21 queries.