FYI web dev is for web design, webpages. This is the right place for programming.
Is it possible to draw shapes in the console? That would be interesting for games and stuff.
EDIT:
Sorry wrong thread.
[QUOTE=Ziks;33953233][url=http://anyhub.net/file/3EuI-release.7z][img]http://f.anyhub.net/4LAJ[/img][/url]
Should be fixed on nVidia cards now. I forgot to write a GL2 version of some shaders so if you have an old card it may not work. If it doesn't work for you please can you post your card and the highest OpenGL version supported by your drivers.
[editline]29th December 2011[/editline]
There's a known bug when you have a reflective surface crossing another surface, fixing that now.[/QUOTE]
nVidia GeForce GT 420M, I can't find what version of OpenGL it supports - but it supports DX10 if that's any help. Nothing happens when I open the game. Empty window.
I have an integrated intel card, also empty window
[QUOTE=Ziks;33953233][url=http://anyhub.net/file/3EuI-release.7z][img]http://f.anyhub.net/4LAJ[/img][/url]
Should be fixed on nVidia cards now. I forgot to write a GL2 version of some shaders so if you have an old card it may not work. If it doesn't work for you please can you post your card and the highest OpenGL version supported by your drivers.
[editline]29th December 2011[/editline]
There's a known bug when you have a reflective surface crossing another surface, fixing that now.[/QUOTE]
Nvidia GeForce GTX560Ti. Works perfect :D
[QUOTE=Ziks;33953233][url=http://anyhub.net/file/3EuI-release.7z][img]http://f.anyhub.net/4LAJ[/img][/url]
Should be fixed on nVidia cards now. I forgot to write a GL2 version of some shaders so if you have an old card it may not work. If it doesn't work for you please can you post your card and the highest OpenGL version supported by your drivers.
[editline]29th December 2011[/editline]
There's a known bug when you have a reflective surface crossing another surface, fixing that now.[/QUOTE]
Radeon HD 6850 works great. However, after like 50 mirrors are placed down, it lags like a mofo.
Why does it say G toggles 'ghost' and then later that it toggles colors?
[QUOTE=Ziks;33953233][url=http://anyhub.net/file/3EuI-release.7z][img]http://f.anyhub.net/4LAJ[/img][/url]
Should be fixed on nVidia cards now. I forgot to write a GL2 version of some shaders so if you have an old card it may not work. If it doesn't work for you please can you post your card and the highest OpenGL version supported by your drivers.
[editline]29th December 2011[/editline]
There's a known bug when you have a reflective surface crossing another surface, fixing that now.[/QUOTE]
Works great over here. NVidia GTX570, OpenGL 4.2.
[img]http://www.1337upload.net/files/147Untitled.png[/img]
[img]http://www.1337upload.net/files/32Capture.PNG[/img]
This makes it lag horribly. :V
Also, frametime(FT) sometimes goes negative. :V
[editline]29th December 2011[/editline]
Goddamnit ninja'd twice :C
[editline]29th December 2011[/editline]
[QUOTE=i300;33954796]NVidia GTX570, OpenGL 4.2.[/QUOTE]
Does it work or not?
[QUOTE=Darwin226;33951068]No it isn't. Efficiency has nothing to do with that. If it was that important they would have written it in asm since the performance difference is negligible.[/QUOTE]
if()
goto:
is 1 je
vs
[code]
for()
{
for()
{
...
if()
{
blah = true;
break;
}
}
if(blah)
break;
}
[/code]
thats 1 jne for the first if
1 register set to true (may involve copying an old register to memory to make room as well)
the jmp for break
then finally another je if blah is true.
so 1 instruction vs 4 instructions (possibly more if no available registers)
[img]http://i52.tinypic.com/xgf6o9.png[/img]
It looks like perlin noise
If it doesn't work for you try this: [url]http://anyhub.net/file/OKM-debug.7z[/url]
If it still doesn't work then can you upload the debug.log it generates and send it my way. Thank you everyone who has tested so far, I should note that in the game I'm hoping to use this in you will never get more than like 10 mirrors at a time.
[editline]29th December 2011[/editline]
[QUOTE=DeadKiller987;33954778]Why does it say G toggles 'ghost' and then later that it toggles colors?[/QUOTE]
Ghost was an old thing that I removed earlier today, forgot to take that text out though. Thanks for spotting it.
[editline]29th December 2011[/editline]
Happy 0x100'th post
Works great for me!
[QUOTE=Ziks;33953233]If it doesn't work for you please can you post your card and the highest OpenGL version supported by your drivers.[/QUOTE]
Surprisingly it works perfectly on linux, GTX 260. Kudos to you.
[QUOTE=Naelstrom;33955340]Surprisingly it works perfectly on linux, GTX 260. Kudos to you.[/QUOTE]
That's a relief, I tried to keep linux in mind while writing but I hadn't had time to test it myself.
[QUOTE=Ziks;33953233][url=http://anyhub.net/file/3EuI-release.7z][img]http://f.anyhub.net/4LAJ[/img][/url]
Should be fixed on nVidia cards now. I forgot to write a GL2 version of some shaders so if you have an old card it may not work. If it doesn't work for you please can you post your card and the highest OpenGL version supported by your drivers.
[editline]29th December 2011[/editline]
There's a known bug when you have a reflective surface crossing another surface, fixing that now.[/QUOTE]
Works fine here, Windows 7 x64, ATI Radeon HD5750.
[QUOTE=Ziks;33955098]If it doesn't work for you try this: [url]http://anyhub.net/file/OKM-debug.7z[/url]
If it still doesn't work then can you upload the debug.log it generates and send it my way. Thank you everyone who has tested so far, I should note that in the game I'm hoping to use this in you will never get more than like 10 mirrors at a time.
[editline]29th December 2011[/editline]
Ghost was an old thing that I removed earlier today, forgot to take that text out though. Thanks for spotting it.
[editline]29th December 2011[/editline]
Happy 0x100'th post[/QUOTE]
Black screen.
[url]http://pastebin.com/8ggGbk6g[/url]
(Same card, nVidia GeForce GT 420M)
[QUOTE=Bang Train;33954881]if()
goto:
is 1 je
vs
[code]
for()
{
for()
{
...
if()
{
blah = true;
break;
}
}
if(blah)
break;
}
[/code]
thats 1 jne for the first if
1 register set to true (may involve copying an old register to memory to make room as well)
the jmp for break
then finally another je if blah is true.
so 1 instruction vs 4 instructions (possibly more if no available registers)[/QUOTE]
If you need every cycle then you shouldn't be writing C.
I don't know what you're even talking about but could it be for branching reasons?
[img]http://i.imgur.com/wEo6u.png[/img]
Really cool. Are you going to make it into a game?
[QUOTE=Bang Train;33954881]if()
goto:
is 1 je
vs
[code]
for()
{
for()
{
...
if()
{
blah = true;
break;
}
}
if(blah)
break;
}
[/code]
thats 1 jne for the first if
1 register set to true (may involve copying an old register to memory to make room as well)
the jmp for break
then finally another je if blah is true.
so 1 instruction vs 4 instructions (possibly more if no available registers)[/QUOTE]
Optimizing C/C++ on such a small scale is silly as the optimizer will do a way better job when compiling.
[QUOTE=Jookia;33955860]If you need every cycle then you shouldn't be writing C.[/QUOTE]
Sure, because bearing in mind small optimisations while writing code is only something you should only be doing in asm
[img]http://i55.tinypic.com/fp2qud.png[/img]
[QUOTE=Ziks;33955822]Try this: [url]http://anyhub.net/file/4Red-debug.7z[/url][/QUOTE]
It works, but there's no text on the screen.
[editline]29th December 2011[/editline]
[url]http://pastebin.com/6Sgnr3Ew[/url]
[QUOTE=supersnail11;33956028]It works, but there's no text on the screen.
[editline]29th December 2011[/editline]
[url]http://pastebin.com/6Sgnr3Ew[/url][/QUOTE]
Fingers crossed: [url]http://anyhub.net/file/4sXT-debug.7z[/url]
And thank you for testing this for me, you've been a great help.
[editline]29th December 2011[/editline]
[QUOTE=Vampired;33955921][img]http://i.imgur.com/wEo6u.png[/img]
Really cool. Are you going to make it into a game?[/QUOTE]
Thank you. I'm working on this with a friend who thought of a game based on light, although I think he wants to keep the game idea secret for now so I can't say much more. You can guess that it will be a puzzle game.
[QUOTE=esalaka;33955886]I don't know what you're even talking about but could it be for branching reasons?[/QUOTE]
Pretty much this:
[QUOTE=Icedshot;33955937]Sure, because bearing in mind small optimisations while writing code is only something you should only be doing in asm[/QUOTE]
[QUOTE=Ziks;33956127]Fingers crossed: [url]http://anyhub.net/file/4sXT-debug.7z[/url]
And thank you for testing this for me, you've been a great help.
[editline]29th December 2011[/editline]
Thank you. I'm working on this with a friend who thought of a game based on light, although I think he wants to keep the game idea secret for now so I can't say much more. You can guess that it will be a puzzle game.[/QUOTE]
Success!
[video=youtube;DZ5nPUYrDO4]http://www.youtube.com/watch?v=DZ5nPUYrDO4[/video]
I added a bunch of stuff like different signs for math.
and a beep noise when you get a problem wrong which weren't captured for some reason.
[QUOTE=Icedshot;33955937]Sure, because bearing in mind small optimisations while writing code is only something you should only be doing in asm[/QUOTE]
Unless the Linux kernel needs to break a nested loop a million times per second, it could do just fine with if statements.
Performance isn't the reason goto is used there. Linus just thinks that it doesn't harm the flow if used right, and I agree with that.
Sorry, you need to Log In to post a reply to this thread.