Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (539)
Games in Android Showcase (132)
games submitted by our members
Games in WIP (603)
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] 2 3 ... 21
1  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-12-12 19:57:35
Got my ray marching terrain working. Added some noise functions, scaled it with a sin(time); interesting results.

https://www.shadertoy.com/view/4tlGzr

I suggest you to go back and fix the light model before going further. Ambient is approximation of indirect light that is coming from every direction. Clamping directional light to small positive value is not equivalent.
2  Game Development / Newbie & Debugging Questions / Re: [LIBGDX] Efficiency problem on: 2014-12-08 18:48:45
Its really hard to understand what you mean because so of loose use of terminology.
3  Game Development / Newbie & Debugging Questions / Re: [LIBGDX] Efficiency problem on: 2014-12-08 16:49:32
What is Cache class and what it does?
4  Discussions / Suggestions / Re: Ability to Remove a Medal on: 2014-12-07 22:14:16
If you accidentally give lollipop to children would you take it away? Assuming police haven't yet arrested you.
5  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-12-06 23:33:57
Extra fuzz pollute registers, instruction cache, branch predicator table. Its also can ide the meaning of important code easily with only marginal gain by not making special case for edges. You are also calculating default value always and this calculation also contain memory read. This may or may not be optimized.
6  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-12-06 19:19:51
1  
2  
3  
4  
5  
6  
7  
   private double getValueOrDefault(float[][] array, int x, int y, double def) {
        try {
            return array[x][y];
        } catch (IndexOutOfBoundsException ex) {
            return def;
        }
    }


This seems extremely odd way to do clamping to edge. You are always calculating that default value and its only used at edges(0.0488221645% of cases with 8k grid). Instead of this I would iterate edges with special case loop and then inner part without extra fuss. I would also unroll the smoothValue method.

7  Discussions / General Discussions / Re: Reasons for using a scripting language in your game? on: 2014-12-06 15:26:30
To be honest , the way computers are heading is most likely going to mean that future programmers will sort of shrug off on performance just simply to how annoying it is to optimize and how little they would gain from it. But for now scripting is useful , a lot of the previous comments are correct , great for people trying to mod your game , great for loading in external data so that you dont have to right yet another god damn tile class or for things like file handling , python file handling vs java filehandling is a bit step and being able to just call a save script instead of writing out a save class is better. Scripts wouldnt really be performance useful when in a consistent method so you obviously wouldnt use it to handle your tick function. They have their advantages and it;s really a situational thing.

Actual game development is coming totally different direction that your vision suggest. Currenty hype is to get away of redudant overhead(Mantle, metal, dx12, GL next, Data oriented design, more c:ish c++ coding, simd, multithreading, etc). All these need more attention of programmers not less. These all also give you substantial speed gains. Single core performance does not increase fast anymore. You need serious effort to compete. Just look where Unreal engine is heading, hot loadable c++ instead of scripting language.
8  Discussions / General Discussions / Re: Redoing my game engine on: 2014-12-02 19:37:01
No need to waste your time to making engine for use of others. There are really big chances that no one will ever use it even if you would pay them. Just make engine that can barely support your needs. Non used code is biggest sin. Documentation should be non existant just make engine parts that robust and self explanatory that you don't need anything but source code and API. Making engines are fun but only way to push engine to be great is to make it just enough to solve all problems that your use cases(real games) offer. Never try to solve problems that don't exist because then you are creating problems(maintaince, bugs, bloat) not solving.
9  Discussions / General Discussions / Re: Difference between libGDX and Swing And Java on: 2014-12-01 18:36:41
Don't worry about performance before you understand the fundamentals.
10  Games Center / WIP games, tools & toy projects / Re: SilenceEngine - A 2D/3D Game Engine on: 2014-11-24 21:49:47
Can you elaborate reasons behind making yet another "engine". What are motivates. Why this is better than others or is it(in the future)? What is the future goals? Is this just for learning? Do you have game what drives the development?
11  Discussions / Miscellaneous Topics / Re: How memory works? on: 2014-11-14 21:30:48
In Java, everything is heap allocated.

Just to be clear, Objects are heap allocated. Primitives (like ints, doubles and pointers) are (since their size is known) allocated on the stack.

Computerphile has a video on stacks and why they are fundamental to how we do computation: https://www.youtube.com/watch?v=7ha78yWRDlE
If you liked that, you should go and watch as much of their other stuff as you have time for. It's good stuff.

Nothing says that objects are heap allocated. You just don't have the control. Because of this JVM can optimize allocations away if its like.
12  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-11-11 19:15:40
Update on my order-independent transparency algorithm.

What you plan to do with the algorithm? Write a paper from it? Keep it as secret? Share it? Its sounds very interesting and I can't wait to see how well its work on different use scenarios.
13  Java Game APIs & Engines / OpenGL Development / Re: [GLSL] Terrain multitexturing shader is too slow on: 2014-11-11 00:28:18
Ofc I meant uniform vec4 tiles.
14  Java Game APIs & Engines / OpenGL Development / Re: [GLSL] Terrain multitexturing shader is too slow on: 2014-11-10 21:49:57
I meant textureLocations uniform array.
15  Java Game APIs & Engines / OpenGL Development / Re: [GLSL] Terrain multitexturing shader is too slow on: 2014-11-08 12:18:49
How does performance goes if you replace uniform array with 1d texture LUT. This way you get away from all integer based dynamic indexing.
16  Discussions / Miscellaneous Topics / Re: simplifying getter/setter classes on: 2014-11-07 22:29:59
There seems to be an assumption here that setters just set a variable and getters just return a variable.  The majority of uses of setters in my code do much more than that - validate values, fire listeners, invalidate caches, etc.  Even for those minor cases that it is a 'pure' setter, I'd rather leave the option open to add these things in without massive refactoring - even in a private codebase that's still more of a PITA than writing a few setters!

2c  Grin

If your setters are doing that much stuff you are doing it wrong.
17  Discussions / Miscellaneous Topics / Re: simplifying getter/setter classes on: 2014-11-07 00:33:06
Still quite a lot of front-end Java work around as far as I can see, though not as much.
I would love to work as a Swing (or JavaFX) developer the rest of my life.

That would sound extremely depressing.
18  Discussions / General Discussions / Re: What defines a Game Library or Collection of Utilities on: 2014-11-06 00:28:41
Good library solve only one problem and does it elegantly.
19  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-11-05 21:06:36
I'm in shock... I think I found the holy grail of graphics programming... I'm literally getting cold sweat...

I solved transparency sorting. I get perfect quality without any pre-sorting at all; not on the CPU or the GPU. I just throw stuff at it and it works. It is completely order-independent. No depth peeling. No stupid additive blending weighted by depth that corrupts color. No shitload of layers to make it look good. No GPU linked lists. Just 4 render targets and 2 passes of all transparent stuff, constant time regardless of view. And then it just works, at perfect quality. At half resolution 1920x1080p, it only uses 13MBs of memory, CONSTANT.

There's no compromise anywhere. It uses a constant amount of memory, runs in constant time, handles any amount of overdraw and always gives correct results. W-what do I do?! Who do I talk to?!

How does that cube shot look when you have actually translucent and additive particles in mix? There must be something that you are not telling or yet discovered.
20  Java Game APIs & Engines / OpenGL Development / Re: Temporal Subpixel Reconstruction Anti-Aliasing on: 2014-11-04 22:00:46
http://screenshotcomparison.com/comparison/98800
Added jittered camera to get 2x supersampling like results. Not yet done with triangleId and only using simple depth based rejection.
21  Game Development / Newbie & Debugging Questions / Re: [engine] How to represent object transforms on: 2014-11-02 19:36:51
Store them in decomposed states. This use less memory(16floats vs 8/10(vec3 pos, quaternion orientation, vec1/3 scale)
This way you can also avoid problems related to interpolated rotations, inverse transforms etc. Composing matrix from these hardly use any cpu cycles.
https://github.com/libgdx/libgdx/blob/master/gdx/src/com/badlogic/gdx/math/Matrix4.java#L222
22  Java Game APIs & Engines / OpenGL Development / Re: Temporal Subpixel Reconstruction Anti-Aliasing on: 2014-11-02 17:51:18
What is your heuristic for triangleID? Is it really unique per triangle? How about triangles sharing vertices?
23  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-11-02 14:25:06
Implemented temporalAA. I do resolve before transparent and post process so its fully artifact free. This also help temporal smoothed screenspace global illumination because now input and output is temporally stable.
Did you see my post on temporal SRAA? http://www.java-gaming.org/topics/temporal-subpixel-reconstruction-anti-aliasing/34555/msg/326409/view.html#msg326409
Yeah. Also Unreal prensetation https://de45xmedrsdbp.cloudfront.net/Resources/files/TemporalAA_small-59732822.pdf and Ubisoft ones http://advances.realtimerendering.com/s2014/drobot/HRAA_notes_final.pdf

In Harldand we have very high triangle count >2-3M and about 50% of that is skinned. So any technique that would need extra pass is out off question. Also I am too busy to make anything too sophisticate that also would run on large set of hardware. So I just decided to ditch all camera jittering at all so and use temporal antialiasing just help with temporal shading aliasing and let the fxaa smooth the geometry aliasing. When I get some free time I will put some effort to actually make some high quality antialiasing instead of just temporally stable.
24  Game Development / Newbie & Debugging Questions / Re: Image Effects on: 2014-10-31 23:00:24
Be carefull by chaining many effects serially if you output them to 8bit texture, you will lose precision of original image every time and these errors  just accumulate up and might cause horrible banding. Using +- half bit dither and/or srgb/higher precision after every effect will help with this.
http://loopit.dk/banding_in_games.pdf
25  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-10-31 18:44:39
Implemented temporalAA. I do resolve before transparent and post process so its fully artifact free. This also help temporal smoothed screenspace global illumination because now input and output is temporally stable.
26  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-10-30 23:52:43

Yeah now it look plausible and code seems to be fine.
27  Game Development / Newbie & Debugging Questions / Re: Image Effects on: 2014-10-30 23:49:35
Usually you can find code for any image effect by searching glsl or hlsl shader code. Then just convert that to java code.
28  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-10-30 21:34:58
Tested my memory skills; I haven't done any graphics programming in about 5 months! I wanted to see if I could remember hwo to write a phong lighting shader, and to my surprise I got one working without any Google searches. For some reason I couldn't get any ambient stuff working, which is weird. But here it is, specular equation included: http://goo.gl/9p16Po

I probably messed something up (the specular highlight is crazy, I couldn't make it look semi realistic), also I guessed on what the view vector for the site was. But it looks fine...

Edit: I was being stupid about the specular thing. http://goo.gl/vVA3SZ

You forgot to normalize interpolated normal. Also your light vector isn't normalized. View vector is also wrong.(should be from camera to vertex)
29  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-10-29 17:41:26
On the other hand, I do use anisotropic filtering for particle motion blur. I modify the gradients using textureGrad() and do a single texture lookup for each pixel. Since particles use texture filtering and mipmaps, this looks decent and automatically clamps the maximum blur kernel size to the amount of anisotropic filtering enabled, but it has some limitations. The biggest one is the limited precision of the anisotropic filtering direction. It seems like the anisotropic filtering only works for a limited number of angles, my guess is 32 or 64 discrete angles. For particles, this works pretty well, but I would not want to use it for motion blur, as this could cause weird seams in the blur.

Nice idea, need to test it out. Have you tested extruding particle geometry towards motion vector?  I use this for sparks and other fast moving/emissive particles but it doesn't work at all if particle sprites can have arbitary rotation.
30  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-10-29 10:12:03
Would you be so kind that you would share that motion blur code as reference?

http://www.java-gaming.org/?action=pastebin&id=1115

There's lots of things going on in other shaders though. I have 4 other shaders that do motion blur related work. Two of them are used to calculate the maximum and minimum motion vectors of each tile, the third shader dilates the tiles and checks if the resulting min and max vectors have similar weight (if they do, it outputs (2048, 2048) to signal the motion blur shader that it should use the fast path), and then a fourth shader generates the packed (linear depth, motion vector length) texture. It's not easy to implement unless you already have motion vectors and linear depth textures lying around. =P

You could propably optimize the plain color blur by using bilinear or anistrophic filtering and get away with lower amount of actual samples.
Pages: [1] 2 3 ... 21
 

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

The first screenshot will be displayed as a thumbnail.

rwatson462 (30 views)
2014-12-15 09:26:44

Mr.CodeIt (23 views)
2014-12-14 19:50:38

BurntPizza (50 views)
2014-12-09 22:41:13

BurntPizza (84 views)
2014-12-08 04:46:31

JscottyBieshaar (45 views)
2014-12-05 12:39:02

SHC (59 views)
2014-12-03 16:27:13

CopyableCougar4 (57 views)
2014-11-29 21:32:03

toopeicgaming1999 (123 views)
2014-11-26 15:22:04

toopeicgaming1999 (114 views)
2014-11-26 15:20:36

toopeicgaming1999 (32 views)
2014-11-26 15:20:08
Resources for WIP games
by kpars
2014-12-18 10:26:14

Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50
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!