Jump to content

  • Log In with Google      Sign In   
  • Create Account

Sirisian

Member Since 05 Oct 2005
Offline Last Active Dec 20 2014 12:17 AM

#5178225 GOTO, why are you adverse to using it

Posted by Sirisian on 04 September 2014 - 10:39 PM

I have no aversion. The way I write code means a goto is never necessary. I've never ran into a problem and thought to myself that a goto would be cleanest solution in C#, Javascript or C++. Maybe it's useful outside of those languages. I remember seeing it used in C and that's it. I use lambdas a lot and lambda callbacks rather than returns. It's very flexible especially with asynchronous stuff.




#5175408 GUI Scissor

Posted by Sirisian on 21 August 2014 - 10:24 PM

Assuming you only need rectangles you can just passing in the x, y, width, height region as a uniform to your pixel shader and discarding pixels outside the region.




#5174340 Thesis idea: offline collision detection

Posted by Sirisian on 17 August 2014 - 06:38 PM

Even if your memory requirements were enormous for 3D this might still be an interesting experiment to open the discussion to other methods. In 2D this might be feasible. You can precompute the minkowski sum for each object for every rotation to simplify things down to a point vs the world simulation. If you could interpolate the stored state between different rotations you might end up with a very fast solution. There is already research for dynamic minkowski summations. Sounds like this would take a lot of research though and a lot of memory.




#5170496 College or Solo?

Posted by Sirisian on 30 July 2014 - 09:33 PM

For profit schools are generally a sham. You should be looking at and applying to an accredited university for a CS program. You should be programming by yourself already and when you're getting your degree be programming on the side to build experience. The idea is a well rounded education. Try to get scholarships also if you haven't already.




#5151358 Screenshot of your biggest success/ tech demo

Posted by Sirisian on 04 May 2014 - 12:35 AM

I wrote this a long time ago as a tech demo. A progressive voxel raycaster. (Chrome/Firefox). (Image) It can be written faster, but I always like the effects it gives when rendering using the NASA terrain maps. One day I'll go back and implement lighting for it.




#5122533 Weird (But Simple?) Angle Math

Posted by Sirisian on 10 January 2014 - 12:35 AM

Bzroom actually corrected me on this a month ago. I was using the dot product, but you can simplify some things with the cross product. Core code:

function Update()
{
	var rotationRate = 5 * Math.PI / 180;

	var direction = mousePosition.Subtract(playerPosition).Normalize();
	// Cross product of playerDirection with direction
	var angleError = Math.asin(Vector.Cross(playerDirection, direction));
	// Clamp(angleError, -rotationRate, rotationRate)
	if (angleError < -rotationRate) angleError = -rotationRate;
	if (angleError > rotationRate) angleError = rotationRate;
	// Rotate by angleError
	var temp = Vector.Create();
	temp.X = Math.cos(angleError) * playerDirection.X - Math.sin(angleError) * playerDirection.Y;
	temp.Y = Math.cos(angleError) * playerDirection.Y + Math.sin(angleError) * playerDirection.X;
	playerDirection.X = temp.X;
	playerDirection.Y = temp.Y;
	Render();
}

Javascript demo. (Right click to view source). Should give you the basic idea.




#5113455 How I can reserve an ideea just for me?

Posted by Sirisian on 01 December 2013 - 05:42 AM

Impossible to do. Game concepts can't be patented generally. Your best bet is copyright and trade secrets. That is when you create your characters and world your art and characters will be copyrighted. Trade secrets in this case means don't tell anyone until you release it. After you release it others can copy your gameplay and mechanics as much as they want. It's important if you do something unique to do it the best.




#5113423 Good old multi account problem

Posted by Sirisian on 01 December 2013 - 12:11 AM

Design your game such that multiple accounts offers no benefit? That's really the only way.




#5093502 I would like to officially declare omnidirectional shadow maps as being pract...

Posted by Sirisian on 12 September 2013 - 01:54 AM

You bumped a thread from 2005. That said nowadays you'd just use rectilinear texture warping. Does a similar trick I'd imagine to his code. That is using a low resolution texture and stretching the scene to apply finer detail in certain areas. Could use the technique with a dual paraboloid method. (No need to use a cubemap).




#5076423 RPG Shadows, CSM, TSM, what else?

Posted by Sirisian on 09 July 2013 - 03:17 PM

You can probably use RTW. It's one of the best shadow mapping algorithms.




#5006678 Expensive Post Processing Techniques

Posted by Sirisian on 03 December 2012 - 11:07 AM

If you had a model renderered and a very basic g buffer you could analyze ssao. The many naive approaches are expensive with tons of optimization routes to research.


#4999078 Opinions on my multiplay solution

Posted by Sirisian on 08 November 2012 - 06:33 PM

Just know that 60 updates per second is a lot. Not sure if this is for the Internet, but with TCP you might see stuttering so you might want to lower that down to 10 to 20 in the future depending on your requirements.


#4992938 Displaying Transparent Voxels

Posted by Sirisian on 22 October 2012 - 04:59 PM

This is a rather complex problem using triangle based rendering. Do you need volumetric type effects where the transparency is dependent on the ray distance? Are the volumes a uniform color usually?

One solution is to triangulate your meshes with the same color into single mesh objects and render both the back and front faces using a DX11 order independent transparency linked list approach storing the beginning and end of each volume then in a second pass change the rendering algorithm to use an opacity rendering equation like this.

The alternative is to raycast on the GPU using 3DDDA which requires DX10/11 hardware. You can use a similar opacity function as the one I linked as you raycast the volume.

Note there is a reason why you don't see this much in games. It requires rather advanced solutions to look correct.


#4977504 Valve introduce greenlight fee - is $100 too much?

Posted by Sirisian on 07 September 2012 - 12:20 AM

After rating all the games earlier I definitely supported the 100 dollar price to entry. I like that steam only allows quality applications in. The original list, which has had most of the incredibly bad games removed already, was filling up with cheap ipad games with ports to the PC or promises of a port. Many were just flash games I've played for free on newgrounds.


#4964209 Browser Based Games.

Posted by Sirisian on 29 July 2012 - 01:01 AM

Java or Javascript? Yeah that's all that's really necessary. But yeah you can easily make a game with just HTML5's canvas and Javascript. Or if you meant Java then yes, that has an applet you can use with many ways to make a game. Anything more would depends on the game and your requirements. You left your question kind of open ended.




PARTNERS