Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (109)
games submitted by our members
Games in WIP (536)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1]
1  Java Game APIs & Engines / JOGL Development / [SOLVE] [CgFx] Load effect error on: 2006-01-26 13:26:40
Hi,

I'm trying to load effect from a simple cgFx file.
This is my code :
1  
2  
3  
4  
5  
       CGcontext context = CgGL.cgCreateContext();
      CGeffect cgeffect = CgGL.cgCreateEffectFromFile(context, file, null);
      int error = CgGL.cgGetError();
      String str= CgGL.cgGetErrorString(error);
      System.out.println(str);


File is a String pointing to a correct cgFx file. The return of the function cgCreateEffectFromFile is always null and the report error is "CG ERROR : The compile returned an error."
I'll try to compile the cgFx file using cgc and everything is ok.
I'll try to put this code inside and outside the jogl GLEventListener init function but the result is the same.
I need your help... I don't understand what's wrong...

edit: I found a reference to a cg function (cgGLRegisterStates(context)) that is not bind in jogl. Did the call to this function is already made when I create a context?

solve: that's it. The function cgGLRegisterStates is missing. I've had it inside my own jogl repositorie and everything works kown.
2  Java Game APIs & Engines / JOGL Development / Re: Shader Eclipse Plugin: Second Release (with GLSL) on: 2005-12-19 19:16:19
I'm sorry, i didn't post the new link.

First, the source code is released on sourceforge here: http://sourceforge.net/projects/glshaders/
You can get a zip version of the plugin.

For a web update version, add the site http://trevidos.free.fr/GLShaders to your eclipse update site.

Have fun

Trevidos
3  Java Game APIs & Engines / JOGL Development / Re: JSR-231 buildnight problem on: 2005-11-23 11:06:43
Unfortunately, this is not a rewind problem. I do all the necessery rewind. And also, my data are mapper using the glMapBufferARB function and unmap when I finish my edition.
It's work perfectly if I don't use VBO for indices...
4  Java Game APIs & Engines / JOGL Development / Re: JSR-231 buildnight problem on: 2005-11-21 20:39:46
I have made some test, and the problem seems to be in the VBO, when you put the indices inside in graphic memory...
any idea Ken?
5  Java Game APIs & Engines / JOGL Development / JSR-231 buildnight problem on: 2005-11-21 08:26:05
Hello,

I've got a strange problem with the today buildnight of JSR-231. It's about VBO.
I made some code to display some big triangulatedSurface, using VBO and index.
It's work perfectly on JOGL, and I port it under JSR. I've got a strange problem: in some case, the display crash.
It's crashing in glDrawElements, but not all the time. I suppose it's crashing when I used big vertex pointer/indices.
My surface is composed of 230961 vertices and 460000 triangles.

Any idea?
6  Java Game APIs & Engines / JOGL Development / Re: center of triangle on: 2005-11-18 19:39:43
It's a well know formula:
to find the center of a triangle (gravity center in this case), we used the relathionship: (ABC is the triangle, G, the center, and GX the vector from G to X)
GA+GB+GC=0

GA = [G] - [A]
so:
3[G] = [A] + +[C];

and bingo!
7  Java Game APIs & Engines / JOGL Development / Re: center of triangle on: 2005-11-18 19:10:53
just adding the 3 vertex coordinate and divide by 3...
8  Java Game APIs & Engines / JOGL Development / Re: Shader Eclipse Plugin: Second Release (with GLSL) on: 2005-11-17 23:49:05
A new version is released. It's my buildnight version, but it seems to work enough to be distribute.
NEW
GLSL editor and Compiler. The support is made by using the 3DLab's front end compiler. see 3Dlab web site for source.
You can download a binary version for windows here: http://trevidos.free.fr/cgPlugin/glslc.zip

The new plugin files are there:
http://trevidos.free.fr/cgPlugin/Shaderplugins.zip

As always, send me an email if you have question/suggestion.

Trevidos
PS:
Markus_Persson, rexguo, you can breath now!
9  Java Game APIs & Engines / JOGL Development / Re: Cg Eclipse Plugin: Work In Progress on: 2005-11-15 10:16:08
CgPlugin for eclipse, first release:

DOWNLOAD:
http://trevidos.free.fr/cgPlugin/cgplugins.zip

DOCS:

download and unzip the plugin file into your eclipse' plugin directory. Then, run eclipse.

To active the runtine compilation of the Cg file, you have to activate this mode via a new popupmenu on the project.

Go into the eclipse preferences and find Cg Preferences. Set the location of your cgc file as:

You can also change the editor prefrences:


After that, rename or create new cg file. To run properly the editor and the compiler, the vertex program files must have the ".vp" extension and the fragment program ".fp"
You can used new file command.


For any question and suggestion, send me an email at trevidos@hotmail.com.

In next release, I'll try to add some cool features: auto-completion, auto-indent, GLSL support...
10  Java Game APIs & Engines / JOGL Development / Re: Cg Eclipse Plugin: Work In Progress on: 2005-11-10 17:08:45
However 3dLabs have a 'verifier' available for free from their website. This is basically a compiler just for checking syntax, so that should be good enough. Not sure if it comes with source but it's a command line tool so I suppose you could always parse the output.

That's the way I do for cgc compiler. I only found the source code of the GLSL compiler, and I don't have any C/C++ compiler. I've got only a 56k modem so I can't download a full cygwin/gcc distribution for windows.
Someone can send me the compiler binarys please?

11  Java Game APIs & Engines / JOGL Development / Re: Cg Eclipse Plugin: Work In Progress on: 2005-11-10 15:13:10
It's not an hard work to add an editor or a compiler to eclipse, but it can be just a long work...
In order to add GLSL support, I need:
 - an GLSL compiler
 - the full keywords allowed for editor coloring.

Right now, I prefer first finish the Cg Editor (I work on auto-completion, boring work too...) and in a second pass, see GLSL.
If you have any docs, files... give it to me.


<Edit>
Just a question for the Cg users: do you want to keep the asm file generate by the compiler or no? For the moment, I just compile the cg code with -nocode options, because I never keep the asm file.
What about you?
</Edit>
Trevidos
12  Java Game APIs & Engines / JOGL Development / Shader Eclipse Plugin: Second Release (with GLSL) on: 2005-11-09 10:33:53
I'm currently coding a cg Eclipse plugin in order to create, compile and edit the cg shaders inside the eclipse IDE.
Ritght now, the compiler and the editor is almost finished.

Some prefrences are ready:


I have to work on new Project and New file action, in order to make it easier to use, but the first realesed will be on the week end.

if you are interessed to see and test it, send me an email trevidos@hotmail.com

Regards
--

Vincent Martinez aka Trevidos
Pages: [1]
 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

CogWheelz (18 views)
2014-07-30 21:08:39

Riven (24 views)
2014-07-29 18:09:19

Riven (15 views)
2014-07-29 18:08:52

Dwinin (12 views)
2014-07-29 10:59:34

E.R. Fleming (33 views)
2014-07-29 03:07:13

E.R. Fleming (12 views)
2014-07-29 03:06:25

pw (43 views)
2014-07-24 01:59:36

Riven (43 views)
2014-07-23 21:16:32

Riven (30 views)
2014-07-23 21:07:15

Riven (31 views)
2014-07-23 20:56:16
List of Learning Resources
by SilverTiger
2014-07-31 18:29:50

List of Learning Resources
by SilverTiger
2014-07-31 18:26:06

List of Learning Resources
by SilverTiger
2014-07-31 13:54:12

HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!