Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411283 Posts in 69325 Topics- by 58380 Members - Latest Member: bob1029

March 29, 2024, 02:33:10 AM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsDeveloperTechnical (Moderator: ThemsAllTook)The happy programmer room
Pages: 1 ... 271 272 [273] 274 275 ... 279
Print
Author Topic: The happy programmer room  (Read 673137 times)
ProgramGamer
Administrator
Level 10
******


aka Mireille


View Profile
« Reply #5440 on: March 23, 2019, 05:03:57 AM »

Nice parity with "slurp" and "spit" with file io Cheesy
Logged

ProgramGamer
Administrator
Level 10
******


aka Mireille


View Profile
« Reply #5441 on: April 04, 2019, 04:54:46 AM »

Not sure if it's ever been linked here before, but I came across this written tutorial series on how to make a simple compiler. It's a bit dated and the code examples are written in turbo pascal, but it's well written and very readable nonetheless, and prioritizes clarity and simplicity to make sure everything is understood properly. I'd give it a read if you've ever considered making any kind of language-like tool!

https://compilers.iecc.com/crenshaw/
Logged

InfiniteStateMachine
Level 10
*****



View Profile
« Reply #5442 on: April 09, 2019, 06:04:07 PM »

Relaunched my website after writing my own static site generator. No real good reason to have written a static site generator outside the fact it was fun.

I managed to get it down to almost no javascript. There is a function for switching part of the layout if you are on mobile.

It was pretty fun! It's nice to do something completely different than games every once in a while.

http://levelism.com/

edit : repo is here : https://gitlab.com/AlexMcG/staticrazor
Logged

Schrompf
Level 9
****

C++ professional, game dev sparetime


View Profile WWW
« Reply #5443 on: April 09, 2019, 10:21:37 PM »

Looks good! And the exact same day I talked to colleagues about redoing my website with static generation. Last version is 10 years old now, still using PHP3 and a handcrafted content management system because It's How You're Doing It (tm) back then.
Logged

Snake World, multiplayer worm eats stuff and grows DevLog
InfiniteStateMachine
Level 10
*****



View Profile
« Reply #5444 on: April 10, 2019, 05:42:04 PM »

Thanks!

It was pretty much the exact same situation for me when I chose to do this project.

I was previously on wordpress and over the years I started to gain an appreciation for non-proprietary formats and having to write everything in the webform box for wordpress was really starting to bug me.
Logged

oahda
Level 10
*****



View Profile
« Reply #5445 on: April 12, 2019, 05:25:15 AM »

Cool! I'm mostly out of the loop when it comes to modern web too, but I did have a chance to play with Vue and Firebase last year, interesting stuff… Still I tend default to PHP when I don't need anything particularly fancy (which is pretty much all of the time since I don't really do web anymore).

Also continued thanks for allowing me to borrow space and subdomain from you. <3

Schrompf, I could swear I was using PHP5 ten years ago, was it really not out back then? o_o
Logged

FrankForce
Level 2
**


This tepid water is tasteless.


View Profile WWW
« Reply #5446 on: April 12, 2019, 07:19:50 AM »

I love javascript.

I've been a C++ programmer for over 20 years. It was my favorite language up until a month ago. The ease and speed I can develop small games in javascript is far beyond what I could do in C++, UE4, or anything else I've used. The speed of iteration is just incredible. The amount of features available in vanilla javascript is astounding and the architecture is easy to grasp. It feels like a whole new world has opened up to me.

My advice for any programmer is make a small game in Javascript. Don't use any additional libraries, don't use any additional assets, keep it all in one html file. Use source control though. (Always practice safe coding.) You will have the time of your life. Check out this year's js1k games if you want some inspiration. Also I have been using Brackets to develop in, I would recommend using that if you need an editor. Have fun!
Logged
Ordnas
Level 10
*****



View Profile WWW
« Reply #5447 on: April 15, 2019, 03:25:05 AM »

Never used for projects JavaScript but it's features are really cool. But I never think that it could be possible to make a game with it without a side library.
Logged

Games:

Crimsontide
Level 5
*****


View Profile
« Reply #5448 on: April 15, 2019, 11:06:08 AM »

I love javascript.

I've been a C++ programmer for over 20 years. It was my favorite language up until a month ago. The ease and speed I can develop small games in javascript is far beyond what I could do in C++, UE4, or anything else I've used. The speed of iteration is just incredible. The amount of features available in vanilla javascript is astounding and the architecture is easy to grasp. It feels like a whole new world has opened up to me.

My advice for any programmer is make a small game in Javascript. Don't use any additional libraries, don't use any additional assets, keep it all in one html file. Use source control though. (Always practice safe coding.) You will have the time of your life. Check out this year's js1k games if you want some inspiration. Also I have been using Brackets to develop in, I would recommend using that if you need an editor. Have fun!

Any good resources for learning it at a low level?  Everything I can find is either high level/geared towards web pages, tied to some particular companies tech, or the latest 'buzz word of the week' nonsense.
Logged
InfiniteStateMachine
Level 10
*****



View Profile
« Reply #5449 on: April 15, 2019, 07:01:44 PM »

Cool! I'm mostly out of the loop when it comes to modern web too, but I did have a chance to play with Vue and Firebase last year, interesting stuff… Still I tend default to PHP when I don't need anything particularly fancy (which is pretty much all of the time since I don't really do web anymore).

Also continued thanks for allowing me to borrow space and subdomain from you. <3

Schrompf, I could swear I was using PHP5 ten years ago, was it really not out back then? o_o

I must admit I've looked at Vue and Angular with interest but I guess at this point they seem more like application frameworks with a relatively large learning curve.

I guess the one part of the project a younger me would have considered counter-intuitive is I essentially have to run every possible search and pregenerate a results page. I think my realtime-trained mind was thinking of the performance at the time I generate the webpage without factoring in amortization since other people will just be requesting a page when looking up a tag.

Also no problem, I don't really use my host a whole lot, even less now that everything is statically generated :D
Logged

cypherbrain
Level 0
*


View Profile
« Reply #5450 on: April 16, 2019, 04:29:29 AM »

I love javascript.

I've been a C++ programmer for over 20 years. It was my favorite language up until a month ago. The ease and speed I can develop small games in javascript is far beyond what I could do in C++, UE4, or anything else I've used. The speed of iteration is just incredible. The amount of features available in vanilla javascript is astounding and the architecture is easy to grasp. It feels like a whole new world has opened up to me.

My advice for any programmer is make a small game in Javascript. Don't use any additional libraries, don't use any additional assets, keep it all in one html file. Use source control though. (Always practice safe coding.) You will have the time of your life. Check out this year's js1k games if you want some inspiration. Also I have been using Brackets to develop in, I would recommend using that if you need an editor. Have fun!

Any good resources for learning it at a low level?  Everything I can find is either high level/geared towards web pages, tied to some particular companies tech, or the latest 'buzz word of the week' nonsense.

The "You Don't Know JS" series is good for this. I have read the first two and they do a great job of illuminating some of JavaScript's dark corners. If I used JS more often, I'd definitely read the rest. They're available at the github repo below.

https://github.com/getify/You-Dont-Know-JS
Logged

Crimsontide
Level 5
*****


View Profile
« Reply #5451 on: April 16, 2019, 02:35:25 PM »

The "You Don't Know JS" series is good for this. I have read the first two and they do a great job of illuminating some of JavaScript's dark corners. If I used JS more often, I'd definitely read the rest. They're available at the github repo below.

https://github.com/getify/You-Dont-Know-JS

Thank-you Smiley  I'm reading it already!
Logged
InfiniteStateMachine
Level 10
*****



View Profile
« Reply #5452 on: April 16, 2019, 07:55:13 PM »

How do people get graphics on the screen with JS these days? What are the good/popular libraries for this kind of stuff?
Logged

FrankForce
Level 2
**


This tepid water is tasteless.


View Profile WWW
« Reply #5453 on: April 16, 2019, 10:24:49 PM »

To start out I recommend just playing around with the 2D canvas. The canvas rendering library is powerful and easy to use. There are other ways to do graphics though. A simple way is to just output html code, I made 2 games using that. You can even use webgl to do fancy 3d graphics and shaders, it's a bit more complex to set up though.

I think the js1k website is actually a great resource for learning javascript. Most of the demos provide unminified original source code that is extremely helpful for learning how to do everything you need to make a game.

Dwitter is also really fun to play around with. 140 byte javascript demos, lots of great stuff to learn there.
Logged
InfiniteStateMachine
Level 10
*****



View Profile
« Reply #5454 on: April 18, 2019, 06:07:13 PM »

Dwitter is awesome! This is the social media site I never knew I wanted :D
Logged

Guntha
Level 0
***


View Profile WWW
« Reply #5455 on: April 30, 2019, 03:50:50 AM »

Went from this:

To this:

After a few weeks. Not completely satisfied with the resulting performance improvement, and I'm afraid the decrease in draw calls plays only a minor part in this improvement because of all the other small optimizations I made along the way, but both screen shots have been made while in debug mode on a debug build, with DirectX12's debug stuff activated, and D3D12 does a lot more work in this mode.
Logged

Schrompf
Level 9
****

C++ professional, game dev sparetime


View Profile WWW
« Reply #5456 on: May 01, 2019, 10:14:28 PM »

Not to downtalk your optimisations, but if you're using DX12, then you're most probably developing on Visual Studio. And that means Debug performance is as much as 60 times away from release performance. I seriously hope you're not measuring, profiling and optimizing a Debug Build only.
Logged

Snake World, multiplayer worm eats stuff and grows DevLog
Guntha
Level 0
***


View Profile WWW
« Reply #5457 on: May 02, 2019, 07:30:01 AM »

Yes, there was pretty much zero performance improvements when comparing profiles of the release builds, and the same optimizations on the OpenGL version of the game actually made performance a lot worse x) (unnoticeable on my main dev machine, but on an older Windows 7 laptop, I went from close to 60 fps to 20-30). After that I went back from the old-school batching I was doing to doing lots of draw calls again, but minimizing state changes between each draw call, and everything is much better.

Basically all I had done was moving the work from the D3D12 API, which was doing a lot of extra work in debug mode, to some homemade solutions that didn't have the same debug overhead.

After that I stopped profiling anything in a debug build.

The fact that I thought less draw calls would be better is that I had, and I still have, a call to SetGraphicsRootDescriptorTable(), which is made for setting the constant buffer for each draw, take a large percentage of processing time according to my profilings, and I can't find an explanation for this, or someone who has the same issue.

In the end, I think what improved performance the most was that I removed a lot of matrix products that were not needed...
Logged

FrankForce
Level 2
**


This tepid water is tasteless.


View Profile WWW
« Reply #5458 on: May 02, 2019, 12:05:47 PM »

I'm happy because by a miracle of the gods I was just barely able to fit a bytebeat music player into a 140 characters of javascript so I can dweet it. Though it seems small, I spent many hours on this after I had already spent many hours before getting the audio player code as small as I thought possible at the time.

https://www.dwitter.net/d/13579




Logged
InfiniteStateMachine
Level 10
*****



View Profile
« Reply #5459 on: May 02, 2019, 06:33:25 PM »

Not to downtalk your optimisations, but if you're using DX12, then you're most probably developing on Visual Studio. And that means Debug performance is as much as 60 times away from release performance. I seriously hope you're not measuring, profiling and optimizing a Debug Build only.

FWIW I've noticed this slowdown is much more apparent when you use STL. The MS debug implementation appears to be crazy slow. It also builds really slow too, I've seen cases where it takes longer than an semi-optimized build.
Logged

Pages: 1 ... 271 272 [273] 274 275 ... 279
Print
Jump to:  

Theme orange-lt created by panic