It was not obvious to me (or documented) that Cube Textures in AGAL need to be uploaded with all mipmap levels.
It was also not obvious to me (or documented) that if you want any mipmapping, you need to upload all mipmap levels.
It was also not obvious to me (or documented) that if you have a non-sqaure texture, you still need to mipmap all the way down to 1x1.
Where should I go to learn stuff like this? Are there better places to start? Otherwise I will slowly de-noobify myself. But gosh golly this seems like basic stuff that should be in the API documentation.
The other side of it is, the tools for debugging stage3D are really pretty bad. So when something is not showing up, I can't debug into the shader or ask the gpu what it thinks, very easily. (maybe I should make some tools here.?) Instead I'm left to cobble together my own checklists like:
- check your math
- short circuit to a known working texture/shader
- think harder
- add shader instructions back in to see if one of them mysteriously breaks something
- google related keywords
- try to think of a way to check intermediate/simpler results
- check your math
screw you linear algebra. I don't need you. I have trigonometry and calculus, I can do just fine!
probably I need a better teacher.
Practice is laudable. It makes you better at your craft. It's just what you do when you want to be good at something.
Software, oh software. Programming a computer is great because you write a thing once, and then THE COMPUTER DOES IT FOR YOU. You're done. You can check out. And the story of being a software engineer is the story of understanding problems, solving them in code once, and then letting the computer solve them from that point forward. If you never revisit your code, it might be because you did it right.
There's a disconnect here. As a programmer I'm attracted to the idea that I can solve a new problem every day, and accrue a mountain of functionality on which to perch, a labyrinth of routines and subroutines from which I need never venture. But if I ever succeeded, my very success would drive me mad from boredom. As a human animal I need the routine of solving problems. I need the practice to hone my skill. But my very success sabotages my own mental health. At large scale, it is a delicious psychological vignette.
but not too dry.
I read the gang of four design patterns book a while ago and I've been thinking about it a bit. Aside from the patterns, which are whatever, the actual premise of the book is really interesting, which is that these patterns come up again and again and again in software development.
That's difficult to reconcile with the DRY principle, or at least it admits defeat. It says, you will write this many times, so at least write it the same way each time, ok?
This is a little bit what I was trying to get at in the previous post; code reuse is a ruse. It almost never happens in the real world, at least not the way we want it to. As a programmer, I am chasing this fantasy that I will write a thing once, and then it will be Written, and I may Reuse it for the rest of my life.
But the fact is, code is actually easier to write than it is to read. So, six months from now when I've forgotten al the details of what I just wrote, I will happier to write it again than to try to understand what I wrote previously. Sad but true.
Taking that conclusion and applying it back to the DRY principle is interesting. It suggests limits on how seriously we should take the principle. I am actually a huge believer in DRY as a heuristic for class and module design. At a code level it makes a ton of sense. But over time, and over large teams, it breaks down. It may be worth repeating yourself, in order to avoid the hassle of creating a dependency. It may be worth repeating yourself, in order to create a new local version of the same knowledge. As broken as that sounds.
The result of making this compromise consciously is something in between code and data. "Script" is the closest word for it. I've been thinking a lot about the continuum of art-design-code-system-hardware, and it's interesting to me how different people gravitate to different points on the scale.
The people who live over on the right have a bad attitude, in my opinion, towards anyone to the left of them. I get to say that because I could be one of them, if I wanted to. So I tell myself.
Runaway abstraction is an occupational hazard. You can find lists of software design principles, and coding principles, laws, rules, etc., that are all aimed at giving programmers heuristics for writing "better code." As an occupational programmer, it is really really easy to start to believe in these heuristics.
But hey, sometimes a scripting language is the right tool for the job.
Sometimes there is no clear line between code and data.
Sometimes a hack is the right answer.
Sometimes an abstraction layer is a mistake, and sometimes it's a critical improvement.
In doing code reviews, especially for external teams / contractors, I'm in a curious position where I may choose to impose my heuristics on other people's code.
Each defect I log is a minor crisis of conscience, where I pass judgement, create work, and reject another professional's opinion. So I must weigh that cost against my belief that I am driving them to "better code."
The decisions are necessary and I make them quickly, most of the time. It's an interesting journey.
I read this post about Emacs (don't get me started please) and some of the features he describes made me realize how low our standards are for usability of a command line interface.
Much in the same way that Microsoft hasn't fundamentally improved MS Paint since well, ever, it is my perception that command line interfaces haven't significantly improved since well, Unix.
I might be wrong, I am not a CLI guy. But here's what I keep looking for that I don't find:
- resize the window with my mouse and have that be meaningful (change the number of columns interactively)
- select, copy, paste text with common mouse and keyboard commands
- autocomplete, intellisense
- persistent command memory (across sessions)
- directory awareness, content visibility
- application awareness (ant, maven plugins that autocomplete targets, projects, etc.)
- hey, tabs?
- unlimited or very large buffer (like a txt file in an editor. You delete history when I tell you to, stupid computer.)
- saving sessions and/or making results accessible as text files
- text folding so I can hide verbose output
I work primarily in Windows, and I've been looking for a DOS prompt replacement that gives me any of this, and I've always been very underwhelmed. It's like getting excited about the next version of windows because you think MS Paint might suck less. Eternal disappointment.
I can see that a lot of what I'm asking for is what Emacs seems to provide, which is basically that your commands are editable in a sane and modern way. Does anyone actually use this feature? And, am I alone? Does the Linux CLI suck just as bad as the Windows prompt? Or am I asking for things that I can never have for some (historical, bad) reason?
Stuff like this really makes me question my own sanity, because the gaping lack of quality tears at my face every time I use these tools, but the people who use and advocate this stuff don't seem to notice it. Perhaps they know tricks I don't, but I think they've just gotten really good at MS Paint.
Also to the point of the article, the big win is not so much that everything is text. It's that somebody paid attention to how the tool is actually used, and put some effort and imagination into it.
but the baby physics engine* is looking pretty good, I've got angular joints working now (though they don't handle torsion? I think that's a separate joint?) and stick joints look pretty good too, and I built a little inspector panel with tabs so that I can easily tweak stuff. And the math is all in 3D, which is a bit of a leap for me (much more thinking... such a pain.)
Unit testing is still a little unfamiliar to me I must admit, but I'm enjoying the added confidence it gives me about the math I'm using. Now it might be time to work on plant biology and rendering, which is after all what I sat down to do in the first place before I got distracted by all this 3d math.
Or, it might be time to head over to the beach I guess.
*Annie likes to call it a "baby-physics engine" instead of a "baby physics-engine." I like the mental image. :-)
Kauai is not one of those places though. Neither is the the Grand Canyon (actually grand). But yeah Hawaii in general is a little mind-blowing.
We were walking through the grounds of a hotel down the coast from where we're staying (in a condo cause it's cheaper and way better) and I got to thinking about how posh hotels terrify me.
Not as a guest. They terrify me from business perspective. It's such an amazing risk, to take, what, tens of millions of dollars and sink it into building a resort on some piece of coast near a natural wonder, with the confidence that you can earn it all back and change, in what, 5 years, 10 years, what? And all of the tens of thousands of details that go into it.
Anyway the magnitude of the business venture staggers me a little, and it makes me a little queasy to be a place like that, because it puts me in mind of the kind of people that could pull that off. I know I guess that they're just people on some level, but on another more childish level I suspect them of being well basically, cold calculating psychopaths, to be able to risk that much.
Which goes to show that I am still a small town boy, fresh off the farm, etc.. I have relatively small ambitions on that scale. Build a castle. Doesn't sound so hard.
Also I'm having a good time working on a grass growing sim in my down time. :-) I'll post the results if there are any.
*we got married!!! it was great. pictures may show up at some point.
It got me thinking about my profession. A lot of what makes me good at my job is incredibly arbitrary, like knowing what connects to what, and who worked on that. But then again a lot of it is what you might call "intrinsic." I like finding out how stuff works. I like solving hard problems. I hate admitting defeat. I enjoy finding workarounds. That sort of thing.
But there's another category of traits that is in-between. I understand when to comment my methods and when to move on. I have a feeling for what to name my classes and variables. I have a good hunch for when a breakpoint will tell me something, and when a file search will help. Sometimes I can just type out a class or three. I guess this space in the middle is what I call "software engineering." I place a value on this stuff, which is independent of the value that I place on seniority, and different from the value I place on ability.
Maybe it's simply because I realize, the older get and the more I move around, the less I can rely on ability OR seniority to govern my salary. It's in my interest to promote the value of professionalism at this point in my career.
It's a cute little two house setup very similar to ours. Nice and private in the back. The houses look like they're in decent shape though they probably need new windows and the yard needs a ton of love.
Anyway it made me hungry. After the wedding and a couple other financial milestones are reached, I want to start working on a down payment for something like this... The business makes too much sense.
If you're looking for an investment property in Los Angeles and you aren't brave enough for Boyle Heights, you should consider Hawthorne.
At work I've been doing a lot of advocacy lately, which is a new role for me. But as our little corner of the business is starting to look like it's in pretty good shape, I'm able to pull my head out of the code for long enough to notice that there are other departments, too. So some of this socket server stuff I'm working on at home is a way of limbering up to tackle the broader challenges at work, I guess.
Sigh. I think about work a lot but, I can't really write about it too much here, because a lot of the stuff I want to talk about it not public knowledge. That's frustrating but I love my job too much to risk it. ;-)
The other thing about this BuildGrow stuff, is that it's a great way of procrastinating. What I should be working on right now is wedding stuff. <_< That stuff is mostly under control I guess. I feel really good about the plans we do have, at least. It's the ones we don't have that are starting to be a concern. I guess we should figure out a honeymoon pretty soon here...
Also my diet is going pretty well. I have about 7 pounds to drop to reach my long-term goal, which is to be 185 at our wedding. I think I will make it. Then after the honeymoon I'll have to work on getting back down to it. Then I'll reevaluate.
There's a lot of crunchy minecrafty, dwarf-fortressy stuff on my mind these days, and a lot of wedding and adulthood stuff too, but I want to break all that out into separate posts.
I want to be the kind of person who keeps learning, and keeps doing cool things, basically indefinitely. In order to live up to that image of myself, it's necessary to cast aside another image of myself, namely, that I am a competent person who does everything right the first time. I think my revelation is that inspiration and humility have to go hand in hand. In order to realize the fruits of your inspiration, you need to allow yourself to wade through the mud a bit. You need to get down there and learn, and grow.
Having a good career protects me from having to do that kind of re-evaluation very often, and I'm starting to feel like a weaker person because of it. I think that's funny.
So I'm writing a java socket server for a game, or loose collection of games, that I want to write, probably in AS3. It's provisionally called BuildGrow. We'll see if anything comes out of it, but I've decided that I'm not going to grade myself on the outcome of the project, but rather I'm going to enjoy the process of learning and building. I think that by focusing on that I might be able to recapture some of the fun and excitement that I used to feel about the work I do.
By the way happy new year, and cheers, and everything is going pretty great for me/us. I don't want to let the somewhat melancholy nature of this post to lead you astray; these are excellent problems to have, and I am happy to be at a point in my life where I can worry about tertiary stuff like this. ;-)
The whole experience got me thinking about the power of open land, and the effect that the concept has on us. American history in particular is full of the idea that land is there for the taking: just move in and set up shop. Even setting aside moral/ethical questions, that idea hasn't really been operable for over a hundred years, but I think we find it compelling anyway, because land is so inherently desirable to us. Almost like gold, or jewels.
It gets me thinking about how and where people like to live. People love water, and love to live next to water. People love to live near their food. People love to live next to other people. People love to have their own land. People love to have ownership over their space. From an evolutionary point of view, it makes a lot of sense. Games like Minecraft and Dwarf Fortress hit a lot of these notes, and add just enough game to keep us hooked.
In other news, the job is going well. I'm starting to understand how this place works, and I've been able to solve some hard problems, which is always gratifying. But the double stress of job + diet has been wearing me down, and my home life has been suffering. I've basically been a zombie at home, which is kinda bad. I miss working on stuff and I've been feeling a bit hollow. Probably because I basically just play LoL all the time. Breaking the funk is hard. Maybe I should throw a party and make tacos for everyone. :-P
It's at Riot Games, they make League of Legends. LoL, as they call it, is a free-to-play team PvP DotA-style game.
Um look idunno. But they're in Culver City, which is way way closer than my old job. I've been playing the game like crazy for the past few weeks, Annie can attest, and I'm really excited about working there. Riot owns their own IP, they are their own publisher, they're profitable, and they're growing very fast. That is exciting.
I feel like there's a lot to say about changing jobs, but when it comes right down to it, I'm not sure I need to say it. It's stressful, and I'll miss the old people, and I'm nervous and excited about the new thing. So there you have it, in a nutshell. I am definitely looking forward to having an hour of my day back. More to come.
The only way this makes sense is if you imagine we're actually involved in a sort of global half-racial holy war against Islam. From this perspective, it's sort of like some 'good' Germans trying to set up a Beer Garden in Tel Aviv in 1950 or perhaps 1944. To which folks might say, 'Look, we know you guys didn't do the Holocaust yourselves. And maybe you mean well. But it's just not right. Go somewhere else.' And most of us would probably see the logic of that sentiment.
Now, I get it. Quite a few people think this is precisely the point. (Not a lot of TPM readers. But a lot of people. Let's not kid ourselves.) We are engaged in a half-racial holy war against Islam. It's not us versus a series of interconnected terrorist networks which are relatively small but episodically quite lethal. It's us, the white Christians and our Jewish junior partner sidekicks versus the brown Muslim people. (If you're keeping score at home, let's call it the Judeo-Christians -white jerseys- vs. the Muslims -brown jerseys.) So isn't it a bit soon for these Muslims, even if these are some of the good ones, to come over here from wherever they're from in the Middle East and set up shop on Judeo-Christian territory? Particularly where the first battle of the Holy War was fought? Soon? ... heck, the Holy War is still on. As Eric Cantor said a couple days ago, C'mon!
For the record, I do not believe that we should consider ourselves to be in a holy war. I find the controversy over the Mosque to be embarrassing. But considering this point of view is illuminating. It's a good reminder that other people see the world differently.