code logs -> 2012 -> Mon, 25 Jun 2012< code.20120624.log - code.20120626.log >
--- Log opened Mon Jun 25 00:00:04 2012
00:00
<@ToxicFrog>
I'm used to map being the "build the seq" part, so (map f seq) implies that it is actually creating and storing all of the return values, regardless of what it's wrapped in
00:01
<&McMartin>
I don't know what it really does under the hood there; I'd need to run it under a tracer to see if it does the Haskelly thing where "read in the whole file as a seq and then process it piecewise" turns into a gradually consumed buffered reader.
00:02
<&McMartin>
In othe rnews, I have no idea what I want to play next, now that I've finished Q.U.B.E. and Rayman Origins.
00:03
<&Derakon>
Have you played Rochard?
00:03
<&Derakon>
It's a 2D platformer with a gravity gun, basically.
00:03
<&Derakon>
I enjoyed it.
00:04 himi-cat [fow035@Nightstar-5d05bada.internode.on.net] has quit [Ping timeout: 121 seconds]
00:04
<&McMartin>
I was kind of hoping to pick a game from the 80-odd I own~
00:04
<&Derakon>
Ahh, well, can't help you there.
00:05
<&McMartin>
I "should" be playing Assassin's Creed Brotherhood.
00:13
<@ToxicFrog>
McMartin: how was QUBE, anyways?
00:13
<@ToxicFrog>
Based on the store page, it's either a clever puzzle game or a shitty Portal ripoff
00:13
<@ToxicFrog>
And based on the demo, it's very badly coded~
00:14
<@ToxicFrog>
(but the demo basically consists of the tutorial and nothing else, so I can't actually tell if it's a good game from that)
00:14
<&McMartin>
It's SPECTACULARLY badly coded
00:14 PinkFreud [WhyNot@NetworkAdministrator.Nightstar.Net] has quit [Ping timeout: 121 seconds]
00:14
<&McMartin>
Which means I now also appear to have the Unreal Development Kit on my system, though I don't think I'm licensed to actually do stuff with it
00:15
<&McMartin>
But I can't tell if I really have it since I also have "PROJECT LONG NAME HERE" with its icon under Add/Remove programs.
00:15
<&McMartin>
It's 15 minutes of a clever puzzle game in 3.5 hours.
00:15
<&McMartin>
1.5 hours of which was one, incredibly shitty, puzzle that should have been cut.
00:16
<&McMartin>
It's also told entirely in mime becuase at the last minute the entire devteam became suicidally ashamed of their Welsh accents.
00:16
<&McMartin>
(Not kidding - there was a full script recorded, from what I hear)
00:16
<&McMartin>
Exploiting glitches in the physics is occasionally mandatory to solve puzzles and will occasionally break the game beyond the ability of the reset switch to repair.
00:17
<&McMartin>
By my normal metric, it does not become a "sure, why not" game until $0.75.
00:17
< gnolam>
...
00:19
<&McMartin>
That's adding up the time for the bits where, if not *actually clever* it's at least competent.
00:19
<@ToxicFrog>
Welp
00:19
<@ToxicFrog>
Kind of glad I didn't get the Cube Pack now~
00:19
<&McMartin>
And then deducting points for inventing a new kind of sliding block puzzle even worse than 15-puzzles.
00:19
<@ToxicFrog>
Ok, that is impressive.
00:19
<@ToxicFrog>
In all the wrong ways.
00:20
<&McMartin>
Yeah, I'd be more annoyed if I wasn't burning store credit~
00:20
<@ToxicFrog>
How did you get the store credit?
00:21
<&McMartin>
I was given it by friends for my birthday.
00:21
<&McMartin>
This is the cunning result of their partnership with GameStop.
00:21
<&McMartin>
I guess I should get the easter egg achievement before I uninstall it.
00:50
<&McMartin>
And done.
00:50
<&McMartin>
Also, hm.
00:51
<&McMartin>
I need to remind myself that I often don't need reduce because apply will work just as well for a lot of functions.
00:51
<&McMartin>
"sum" is "apply +"; "concat" is "apply str"
00:52
< celticminstrel>
Because + and str are variadic?
00:52
<&McMartin>
Yup
00:59 You're now known as TheWatcher[T-2]
01:00
< celticminstrel>
I keep pressing Enter after using Xcode's "Edit all in scope" because I'm used to Eclipse's equivalent function that requires an enter to confirm the change... but Xcode just inserts a line break when I do it.
01:01
< celticminstrel>
(Okay, technically it's return, not enter.)
01:02 You're now known as TheWatcher[zZzZ]
01:36 himi-cat [fow035@D741F1.243F35.CADC30.81D435] has joined #code
02:23 Kindamoody[zZz] is now known as Kindamoody
02:31 Attilla [Obsolete@Nightstar-fdbc4a68.as43234.net] has quit [Ping timeout: 121 seconds]
03:31
<&McMartin>
ToxicFrog: You might want to look into "for" in Clojure.
03:31
<&McMartin>
It's... not C's.
03:32
<&McMartin>
My reflex is to use "recur" instead, but I am apparently supposed to resist this urge.
03:38 Vash [Vash@Nightstar-e8057de2.wlfrct.sbcglobal.net] has joined #code
03:38 mode/#code [+o Vash] by ChanServ
04:03 Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Ping timeout: 121 seconds]
04:07 Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code
04:24
<@ToxicFrog>
McMartin: it looks a lot like Scala's, actually
04:27
< Tarinaky>
http://www.vintage.org/features/blinkenlights.html An old one, but a good one.
04:27
<&McMartin>
I kind of prefer recur, but I think that's Scheme talking.
04:28
<@ToxicFrog>
I very prefer recur because it's less complicated and thus easier to use~
04:29
<@ToxicFrog>
Also, problem with -> that pipe doesn't have: it splices the argument directly into the forms, which has issues with #()
04:35
<&McMartin>
Aha
04:35
<&McMartin>
Macro'd
04:37 PinkFreud [WhyNot@NetworkAdministrator.Nightstar.Net] has joined #code
04:37 mode/#code [+o PinkFreud] by ChanServ
04:40 SmithKurosaki [smith@Nightstar-1748d158.home1.cgocable.net] has joined #code
04:42
<@ToxicFrog>
Kind of a bummer that I have to write #(.getCanonicalFile %) rather than just .getCanonicalFile
04:44
< Tarinaky>
Can anyone recommend a fairly painless way of using Python scripts as part of a C++ program?
04:44
< celticminstrel>
Boost Python?
04:44
< Tarinaky>
Is that the best way?
04:44
< celticminstrel>
I haven't actually used it, admittedly.
04:44
< celticminstrel>
So I can't say how good it is.
04:44
< celticminstrel>
But I assume it's probably better than directly accessing the Python C API.
04:45
< Tarinaky>
Is the Python C API particularly bad?
04:45
< celticminstrel>
No idea, but it's a C API. <_<
04:45
< celticminstrel>
Which means I'd probably dislike it regardless of how good it is. >_>
04:45
< Tarinaky>
Boost::Python appears to make heavy use of macros
04:45
< Tarinaky>
Which is the main thing that displeases me in C/C++ >.>
04:46
< celticminstrel>
Macros aren't necessarily a bad thing.
04:46
< Tarinaky>
Neither are gotos.
04:46
< celticminstrel>
I think the only time I've ever used a goto in C/C++ is for the equivalent of a Java labelled break.
04:47
< celticminstrel>
Might be one or two other times that got squashed a little later.
04:47
< Tarinaky>
It was meant as a strawman >.>
04:47
< celticminstrel>
:P
04:48
<@ToxicFrog>
Tarinaky: the Python C API is kind of awkward, especially for embedding
04:48
<@ToxicFrog>
These days it's generally assumed that you will extend with cython and embed with something other than Python.
04:48
< Tarinaky>
At the risk of dooming my current project I want to get into C++0x a little and might try writing a small engine or something.
04:49
<@ToxicFrog>
And yeah, the whole point of boost is that it's mostly-or-entirely based on preprocessor trickery and thus doesn't require any linking or source inclusion, you just need to #include it.
04:49
< celticminstrel>
My only complaint with Xcode's code completion is that it acts as though defaulted parameters do not exist.
04:49
< Tarinaky>
I'd much rather build any UI elements as bits of Python I can call from the C++ though.
04:49
< Tarinaky>
Because otherwise it'll be a nightmare.
04:49
<@ToxicFrog>
Tarinaky: why are you embedding Python in particular, rather than a scripting language designed for embedding?
04:49
< celticminstrel>
I don't think that's entirely the point of Boost...
04:50
< Tarinaky>
Because I already know Python.
04:50
< celticminstrel>
Anyway, you do need linking for Boost Python.
04:50
<@ToxicFrog>
With Python the preferred approach is generally to write the app in it, and then call out to C/++ for the "hard" stuff using cythong.
04:50
< Tarinaky>
I've seen commercial software doing it the other way around though.
04:51
< Tarinaky>
or at least, seeming to.
04:51
<@ToxicFrog>
It's very much "extend, don't embed", in contrast to languages like Lua or Guile which are designed for embedding from day one.
04:51
< Tarinaky>
With bytecode glue and python extensions.
04:51
< celticminstrel>
Um, don't those two ways kinda have contrasting use cases?
04:51
<@ToxicFrog>
Oh, yeah, you can use it as an embedding language, and some projects have
04:51
< Tarinaky>
Or is that just sleight of hand?
04:51
< celticminstrel>
extending vs embedding
04:51
<@ToxicFrog>
some of them with great success
04:52
<@ToxicFrog>
But the C/++ side of things is generally going to be messy compared to an extension-based approach or using an embedding-focused language
04:52
<@ToxicFrog>
ISTR that one of the Civ games used Python as its embedded scripting language, even.
04:52
< Tarinaky>
ISTR?
04:52
<@ToxicFrog>
celticminstrel: yes, which is why a language good at one isn't necessarily good at the other.
04:52
<@ToxicFrog>
I Seem To Recall.
04:52
< Tarinaky>
Yeah, Civ4 was what I was thinking of when I said that.
04:53
< Tarinaky>
Although I think WoW and Eve use Python too.
04:53
< Tarinaky>
But I've never actually installed either of those.
04:53
<@ToxicFrog>
WoW uses Lua.
04:53
< Tarinaky>
Ah, okay.
04:53
<@ToxicFrog>
A shitload of games use Lua for this, actually.
04:53
<@ToxicFrog>
Designed for embedding + fast, small interpreter + very permissive license means a lot of happy game developers.
04:53
< Tarinaky>
Lua never seemed very powerful as a language.
04:54
< celticminstrel>
Gah, I keep forgetting that the second argument to string::substr is length, not endpoint...
04:54
< celticminstrel>
This complicates stuff sometimes.
04:54
<@ToxicFrog>
As for EVE, it uses Python, but not as an embedded scripting language - it's written in Stackless Python primarily.
04:54
< Tarinaky>
Stackless?
04:55
<@ToxicFrog>
A performance-oriented Python implementation that avoids C stack overhead and supports coroutines and microthreading.
04:56
<@ToxicFrog>
And Lua is a very powerful language, it's just very weak on the library front.
04:56
<@ToxicFrog>
Which is a problem if you're developing stand-alone apps in it, but, well, it's an embedding language, the host app is meant to provide the APIs.
04:58
<@ToxicFrog>
So, yeah. You see a lot of stuff developed in Python with C extensions, not a lot of stuff developed in other languages using Python as an embedded scripting language. Other way around with Lua. Different focuses.
05:03
<@ToxicFrog>
That said
05:03
<@ToxicFrog>
You can go either way with either language, and if you want to use Python for this, go for it
05:04
<@ToxicFrog>
Oh hey awesome
05:04
<@ToxicFrog>
.canRead doesn't actually work
05:04
<@ToxicFrog>
ffffffffffffffffffff
05:07
<@ToxicFrog>
Tarinaky: I'm curious - what seemed not-powerful about it?
05:08
< Tarinaky>
Can't remember.
05:08
< Tarinaky>
This was... 2 years ago now.
05:08
< Tarinaky>
My main opposition is just that I don't already know Lua and learning OpenGL and getting up to date on C++0x is 'enough'.
05:09
< Tarinaky>
I should -probably- sleep soon. I am tired and should have gone to sleep a while ago.
05:09
<@ToxicFrog>
Fair enough. If you already know the Python/C API as well there'll be less to get up to speed on.
05:10
< Tarinaky>
I do not, unfortunately.
05:12
<&McMartin>
TF: You seem to be doing very heavy Java interop here
05:13
<&McMartin>
Also: I was given to understand that Civ4 was an extended Python application, not an embedded one.
05:13
<&McMartin>
Could be wrong, easily, but
05:13
<@ToxicFrog>
McMartin: I could also be wrong, I don't actually have Civ4
05:13
<@ToxicFrog>
In which case the set of games I know of that embed Python is, um
05:13
<@ToxicFrog>
Crossfire
05:13
<@ToxicFrog>
Five years ago
05:13
<&McMartin>
Well, I do, but I'm not sure how one goes about *checking*, or distinguishing between an embedded python or an extended python that is also using py2exe
05:14
<@ToxicFrog>
As for the Java interop - for practice I am trying to write a duplicate file detector, and clojure.java.io is pretty sparse
05:14
<&McMartin>
Aha, quite so.
05:14
<@ToxicFrog>
So yeah, there's lots of java.io.File fuckery going on.
05:15
<&McMartin>
... oh hey
05:15
<&McMartin>
OK, CIV is probably embedded python
05:15
<&McMartin>
Given that I see boost_python-vc71-mt-1_32.dll right here.
05:15
<@ToxicFrog>
Which makes me sad when I learn that some of the methods I want aren't available except in V7 java.nio, and others are available earlier but don't work as advertised.
05:16
<&McMartin>
Java is the worst of all languages for filesystem work -_-
05:16
<&McMartin>
I think I may include Haskell in this, where you at least know in advance you'll be FFIing libc
05:17
< celticminstrel>
It's kinda funny; if you try to pass a new expression to a function taking a non-pointer argument, where the types match apart from that, clang's fix-it suggestion is not to remove "new" but add an indirection operator.
05:17
<&McMartin>
Also, I think I know what my new game project shall be.
05:17
< celticminstrel>
Which of course would break your program.
05:17
<&McMartin>
And I have to convince myself that Clojure is a good idea for this as opposed to, you know, Game Maker.
05:17
<&McMartin>
Or, for that matter, Ophis
05:18 iospace is now known as io|t-2
05:18
<&McMartin>
In short: Metroidvania, perhaps in the Manic Miner style since I've been reminded I like that
05:18
<&McMartin>
Our Hero(ine) has an umbrella and every power is a modification *to* the umbrella.
05:18
<&McMartin>
Reinforced struts to ride thermals
05:18
<&McMartin>
Iron tip for weaponry
05:18
<&McMartin>
etc
05:20
< Tarinaky>
I'm currently imagining a Duck fencing with an umbrella rapier.
05:20
< Tarinaky>
I may have jumped a few steps.
05:20 * Tarinaky passes out now.
05:21
<@ToxicFrog>
I'm tempted to see if the .NET file handling APIs are any less terrible and try this in clojure-clr
05:21 io|t-2 is now known as iospacedout
05:32 SmithKurosaki [smith@Nightstar-1748d158.home1.cgocable.net] has quit [Ping timeout: 121 seconds]
05:34
<@ToxicFrog>
Ok, the BCL doesn't even pretend to have those methods in any version as far as I can tell
05:37
<@ToxicFrog>
ahahahahaha what
05:38
<@ToxicFrog>
BCL System.IO.File.Exists returns false if the file exists, but is not readable
05:39
<@ToxicFrog>
Ok, I'm giving up on this for the night
05:53
<&McMartin>
BCL?
05:59
< celticminstrel>
Pre-parsing my text into an intermediate representation has sped up the rendering quite a bit.
06:00
< celticminstrel>
As a bonus, I can now prevent people from scrolling way off the bottom of the help.
06:00
< celticminstrel>
Because I can calculate the total height of the text.
06:01
< celticminstrel>
Downside is that it takes awhile for the initial parsing.
06:01
< celticminstrel>
But I think I can deal with that by loading it in another thread.
06:01
< celticminstrel>
Possibly.
06:15
<~Vornicus>
What sort of intermediate representation are we talking about?
06:16
<~Vornicus>
Is it possible to serialize it?
06:18
<~Vornicus>
If so, you can avoid the parsing step in production by baking your text.
06:19
< celticminstrel>
Um.
06:19
< celticminstrel>
Maybe?
06:19
<~Vornicus>
That /said/, this also suggests you're still Doing It Wrong, as most browsers can be commanded to render HTML in nearly real time.
06:20
< celticminstrel>
I was re-parsing the text every time the view changed. (Just for the visible portion though.)
06:21
< celticminstrel>
The intermediate representation is basically a list of lines that know their height, each of which has a list of elements which know their horizontal location on the screen.
06:23
<~Vornicus>
Do you have text of varying heights?
06:23
< celticminstrel>
Yes, I use three different font sizes and also have embedded images.
06:23
< celticminstrel>
And italics and underline and (potentially) bold.
06:23
< celticminstrel>
I also had support for coloured text, though I didn't actually make use of that yet.
06:33
<~Vornicus>
Rainbow Speak is useful.
06:33
< celticminstrel>
Heh.
06:37
< celticminstrel>
Agh, expanding out long type names in Xcode's variable view makes it completely useless to define a formatter for a complicated template type. :/
06:42 Derakon is now known as Derakon[AFK]
06:47
<&McMartin>
\o/
06:47 * McMartin finds Clojure has delicious curry
06:47
<&McMartin>
It needs more work than in ML/Haskell, but it's there at all, so that's head and shoulders above most LISPs -_-
06:57 Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Client exited]
07:11 You're now known as TheWatcher
07:21 celticminstrel [celticminst@Nightstar-5d22ab1d.cable.rogers.com] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!]
07:23 Kindamoody [Kindamoody@Nightstar-6154a72a.tbcn.telia.com] has quit [[NS] Quit: Changing networks, brb]
07:31 Kindamoody|afk [Kindamoody@Nightstar-6154a72a.tbcn.telia.com] has joined #code
07:31 mode/#code [+o Kindamoody|afk] by ChanServ
07:33 Kindamoody|afk is now known as Kindamoody
08:06 Vash [Vash@Nightstar-e8057de2.wlfrct.sbcglobal.net] has quit [[NS] Quit: I lovecraft Vorn!]
08:12 You're now known as TheWatcher[afk]
08:23 Kindamoody [Kindamoody@Nightstar-6154a72a.tbcn.telia.com] has quit [[NS] Quit: Trying again to switch networks, brb]
08:23 Kindamoody|afk [Kindamoody@Nightstar-cb46b5cc.cust.tele2.se] has joined #code
08:23 mode/#code [+o Kindamoody|afk] by ChanServ
08:24 Kindamoody|afk is now known as Kindamoody
08:35 himi-cat [fow035@D741F1.243F35.CADC30.81D435] has quit [Operation timed out]
09:04 Kindamoody [Kindamoody@Nightstar-cb46b5cc.cust.tele2.se] has quit [[NS] Quit: Switching networks again, brb]
09:05 Kindamoody [Kindamoody@Nightstar-05577424.tbcn.telia.com] has joined #code
09:05 mode/#code [+o Kindamoody] by ChanServ
09:53 Attilla [Obsolete@Nightstar-fdbc4a68.as43234.net] has joined #code
10:13 Kindamoody is now known as Kindamoody|out
10:39 You're now known as TheWatcher
11:10 himi-cat [fow035@Nightstar-5d05bada.internode.on.net] has joined #code
11:45 You're now known as TheWatcher[d00m]
11:59 iospacedout is now known as iospace
12:11 You're now known as TheWatcher
12:16 * TheWatcher eyes this code, wtfs
12:17
<@TheWatcher>
$self -> {"session"} -> create_session($user -> {"user_id"}, $self -> {"cgi"} -> param("persist"), {"savestate" => $self -> get_saved_state()});
12:18
<@TheWatcher>
Except create_session is seeing the savestate hash as its second argument
12:19
<@TheWatcher>
Which should be impossible O.o
12:39
< sshine>
perl?
12:39
<@TheWatcher>
Yup
12:40
<@TheWatcher>
("there's your problem" is not a suitable response, I note :P)
12:40
< sshine>
hehe
12:40
< sshine>
so the savestate hash should be the third argument
12:40
<@TheWatcher>
yep
12:41
<@TheWatcher>
And if I do 'my $persist = $self -> {"cgi"} -> param("persist"); $self -> {"session"} -> create_session($user -> {"user_id"}, $persist, {"savestate" => $self -> get_saved_state()});' it all works
12:43
<@TheWatcher>
It is truly bizarre, as even if $self -> {"cgi"} -> param("persist") returns undef, that should set the second argument to undef.
12:44
<@TheWatcher>
I will come back to it and work out WTF some other time, as I must code like crazy right now...
12:58 iospace is now known as io|driving
14:24 celticminstrel [celticminst@Nightstar-5d22ab1d.cable.rogers.com] has joined #code
14:26 io|driving is now known as iospace
14:33 You're now known as TheWatcher[afk]
14:56
< sshine>
TheWatcher[afk], ah, maybe it is because of the double arrow in the second argument.
14:56
< sshine>
no, wait, that might have been the case if it were a => arrow, but not with a -> arrow, I think.
15:14 EvilDarkLord [jjlehto3@Nightstar-a5db08cc.org.aalto.fi] has quit [Ping timeout: 121 seconds]
15:39 EvilDarkLord [jjlehto3@Nightstar-a5db08cc.org.aalto.fi] has joined #code
15:46
< iospace>
dear board
15:47
< iospace>
why are you only detecting the external harddrive when you're in IDE mode and not AHCI mode D<
15:53 Attilla_ [Obsolete@Nightstar-52effd38.as43234.net] has joined #code
15:54 Attilla [Obsolete@Nightstar-fdbc4a68.as43234.net] has quit [Ping timeout: 121 seconds]
16:00 Attilla_ is now known as Attilla
16:09 Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code
16:14 himi-cat [fow035@Nightstar-5d05bada.internode.on.net] has quit [Ping timeout: 121 seconds]
16:27 himi-cat [fow035@Nightstar-5d05bada.internode.on.net] has joined #code
16:51 You're now known as TheWatcher
16:53 Kindamoody|out is now known as Kindamoody
16:58 * gnolam snerks.
16:58
< gnolam>
You know those warnings accompanying software and hardware saying (IN ALLCAPS, TO ANNOY YOU AND MAKE THEM HARD TO READ) how the product's not allowed near anything nuclear, anything aviation-related, or anything someone could even dream is life-critical?
16:59
< gnolam>
Turns out even small, extremely ruggedized computers have those.
16:59
< gnolam>
So what are we going to use said computer for?
16:59
< gnolam>
To do spectrometry from a small aircraft to help with decision making in radiological emergencies. ;D
17:02
< gnolam>
I think this might be a personal warranty voiding record.
17:08
<@TheWatcher>
Woot! :D
17:11
<&jerith>
gnolam: Nice.
17:32
< Tarinaky>
This infallible artificial intelligence is provided as is, without warranty express or implied.
17:33
< Tarinaky>
While it is, by all practical definitions, foolproof and incapable of error, the manufacturers except no liability for loss including (but not exclusively) loss of data or human crew due to malfunction.
17:34
< Tarinaky>
Operation of the HAL above altitudes of 1,000 above sea-level will void the warranty.
17:35
<@TheWatcher>
"Abandon shop! This is not a daffodil. Repeat, this is not a daffodil!"
17:35
<@TheWatcher>
>.>
17:36 * Tarinaky was expecting a bigger laugh >.>
17:41
<@Tamber>
"...one thousand *what* above sea-level?!"
17:41
<@Tamber>
"I don't know, we just left the damn thing on the ground!"
17:42
< Tarinaky>
Hahaha.
17:42
< Tarinaky>
In my head I was thinking m.
17:42
< Tarinaky>
I dunno how I forgot to type it :p
17:43
< Tarinaky>
Point was: "Silly small number for a space craft"
18:03
< Rhamphoryncus>
"How many atmospheres can it handle?" "Well, it's a spacecraft, so anywhere between zero and one."
18:04
< Rhamphoryncus>
Hmm, AMD's partially resident textures is neat, but alas the address space is too small, heh
18:07
< Rhamphoryncus>
they say "10s or 100s of gigabytes". Their longterm plans seem to involve merging with the CPU, so that should extend to 48-bits or 256 TiB. If I have a billion 1-meter tiles, with procedural generation down to mm precision, that puts me at 50 bits
18:08
< Rhamphoryncus>
Or I could roll my own virtual textures and not need a giant flat address space
18:08
< Tarinaky>
I should write some code... but lazy.
18:11 Attilla [Obsolete@Nightstar-52effd38.as43234.net] has quit [Ping timeout: 121 seconds]
18:20 Attilla [Obsolete@Nightstar-e32c9bdf.as43234.net] has joined #code
18:21
< Rhamphoryncus>
I should too
18:21
< Rhamphoryncus>
I've had enough time pondering, I should get on to coding
18:21 Attilla [Obsolete@Nightstar-e32c9bdf.as43234.net] has quit [Connection reset by peer]
18:22 Attilla [Obsolete@Nightstar-e32c9bdf.as43234.net] has joined #code
18:23 Attilla [Obsolete@Nightstar-e32c9bdf.as43234.net] has quit [Connection reset by peer]
18:23 Attilla [Obsolete@Nightstar-e32c9bdf.as43234.net] has joined #code
18:37 Attilla [Obsolete@Nightstar-e32c9bdf.as43234.net] has quit [Ping timeout: 121 seconds]
18:43 Attilla [Obsolete@Nightstar-fcd97f92.as43234.net] has joined #code
19:13 Kindamoody is now known as Kindamoody[zZz]
19:16
< celticminstrel>
const_iterator models "const T*" or "T*const"?
19:23
<&McMartin>
The former, IIRC; it's what const vectors return
19:27
< celticminstrel>
So then const iterator (without the underscore) is "T*const".
19:28 jeroid [jerith@687AAB.5E3E50.5EC6FB.BF62B5] has joined #code
19:35
< gnolam>
Also, a pox on people who can't use standard communication interfaces.
19:35
<@Tamber>
The pidgeons leaving droppings on your keyboard again?
19:36
< gnolam>
The whole idea is to keep the project hardware COTS, with a minimum of glue in software.
19:36
< Tarinaky>
"Who wrote this silly code."
19:37
< jeroid>
You did. Three weeks ago.
19:38
< celticminstrel>
Heh, I feel that way sometimes.
19:39
< Tarinaky>
If perceptions of bad code are just you learning as you write a program...
19:39
< Tarinaky>
I've obviously learned a lot.
19:39
< celticminstrel>
I also can't remember why I was asking about const iterators.
19:39
< gnolam>
But the choice seems to be between wasting Eris knows how much of the very limited payload capacity on unnecessary hardware, while stacking hacks upon hacks in software... or building custom hardware.
19:40
< celticminstrel>
That said, yay I just nuked a global variable.
19:40
< celticminstrel>
By... moving it inside another related global variable, but still!
19:41
< gnolam>
A choice between getting data over USB and proprietary software that only works on x86 Windows and may actually be impossible to integrate properly... or via nice, standardized SPI with an incomplete sensor module.
19:43
< jeroid>
Isn't SPI COTS?
19:43
< gnolam>
It is.
19:44
< jeroid>
Then what's the problem?
19:44
<@Tamber>
"with an incomplete sensor module." possibly.
19:44
< gnolam>
And there are some nice, extremely light-weight and small-yet-powerful computers that interface with it wonderfully.
19:44
< gnolam>
Yes. That is the problem.
19:44
<@Tamber>
So the options are "Shit that doesn't work" or "Shit that doesn't work, but is standardised"
19:45
< gnolam>
The module is... /almost/ microcontroller/GPIO compatible.
19:46
< gnolam>
Besides, oh, little things like a coax input that's specced at, and I shit you not, "between 0 and -2000 V".
19:46
<@Tamber>
...
19:46
< gnolam>
And no, that doesn't mean "you can feed it anything between those two and it'll still work".
19:46
< gnolam>
It means "the correct value is somewhere in that range".
19:48
< jeroid>
Killervaults.
19:55
< celticminstrel>
Okay so... C++ raw strings do allow unsecaped embedded newlines even though Xcode isn't hiliting the string when there are embedded newlines?
19:55
< celticminstrel>
^unescaped
20:01
< celticminstrel>
I guess they must, since this compiles.
20:09
< Tarinaky>
Stupid question time!
20:10
< Tarinaky>
I need a progression/function that passes through 1/9, 1/25 and 1/50.
20:10
< Tarinaky>
Then I need a pair of functions that given the current position on that function can return a value to the left or right...
20:10
< Tarinaky>
So I'm thinking some sort of list.
20:11
< Tarinaky>
BBut I have no idea how to say "Get the element before this value in that Python list"
20:11
< Tarinaky>
Or if that's even a smart thing to do.
20:28
< Tarinaky>
Seems to have worked...
20:30
< celticminstrel>
I suppose there's no nice clean way to suppress an "invalid conversion specifier" warning?
20:31
<~Vornicus>
Tarinaky: my_list[my_list.index(thingy)-1]
20:33
<~Vornicus>
Also, among others: (23x^2-87x+100)/900
20:34
< celticminstrel>
Nice, I'm adding case statements to an enumeration switch and the code completion omits enumerators that I've already added.
20:36
< Tarinaky>
str(int(d**(-1))) << I can't help but feel there should be a better way of doing that :p
20:36 jeroid_ [jerith@687AAB.5E3E50.5EC6FB.BF62B5] has joined #code
20:36 jeroid [jerith@687AAB.5E3E50.5EC6FB.BF62B5] has quit [Connection reset by peer]
20:36
< Tarinaky>
I should add: it's being concaternated onto the string "1/"
20:39 jeroid_ [jerith@687AAB.5E3E50.5EC6FB.BF62B5] has quit [[NS] Quit: Bye]
20:58
<&jerith>
Tarinaky: That looks like Python.
20:59
<&jerith>
Is it?
20:59
< Tarinaky>
Yes.
21:00
<&jerith>
In [6]: "1/%d" % int(1 / 0.5)
21:00
<&jerith>
Out[6]: '1/2'
21:01
< Tarinaky>
Well... I suppose that's another way to obtain the reciprocal >.>
21:02
<&jerith>
In [7]: "1/%.0f" % (1 / 0.5)
21:02
<&jerith>
Out[7]: '1/2'
21:03
<&jerith>
That rounds instead of truncating if the result isn't integral, though.
21:04
< celticminstrel>
For some reason lldb/Xcode sometimes randomly clips strings.
21:15 * celticminstrel uses sqlite to store scores.
21:21
< gnolam>
"OHP Mega Demo 9000": https://www.youtube.com/watch?v=LCIsIfEOEI8
21:43 ToxicFrog [ToxicFrog@ServerAdministrator.Nightstar.Net] has quit [Operation timed out]
21:44 * gnolam finds yet another reason to dislike Elsevier.
21:44
< gnolam>
They publish the "Journal of Acupuncture and Meridian Studies". >_<
21:49
< Tarinaky>
Who's Elsevier?
21:52
< gnolam>
An evil publisher of scientific journals.
21:52
< gnolam>
(Pleonasm, I know, but still)
21:52
< gnolam>
And, apparently, pseudoscience. :P
21:58 himi-cat [fow035@Nightstar-5d05bada.internode.on.net] has quit [Ping timeout: 121 seconds]
21:59 ToxicFrog [ToxicFrog@ServerAdministrator.Nightstar.Net] has joined #code
21:59 mode/#code [+o ToxicFrog] by ChanServ
22:00
< Tarinaky>
Wasn't there supposed to be something to Acupuncture that made it a statiscially insignificant amount better than a placebo?
22:00
<&McMartin>
Not insignificant
22:00
<&McMartin>
But it also doesn't have anything to do with meridians.
22:00
< Tarinaky>
Putting it into the "Not proved to work" catagory rather than "proved not to work."
22:01
<&McMartin>
Nah, it's in the "works, but don't unless you have to" category like hypnosis.
22:01
<&McMartin>
AIUI.
22:01
< gnolam>
Depends on your definition of placebo.
22:01
< gnolam>
In this case, I'd say the definition is "sham acupuncture", in which case it's not any better.
22:02
<&McMartin>
Yeah, I don't think that's what Tarinaky's talking about.
22:02
< Tarinaky>
I am aware that you don't have to get any qualifications to call yourself an acupuncturist. That doesn't really disprove the actual concept though.
22:02
<&McMartin>
Not what he means
22:02
< gnolam>
It is however better than nothing at all* for pain relief, for the simple reason that someone's distracting you by poking you with stuff.
22:02
<&McMartin>
He means it doesn't outperform randomly poking you with needles.
22:03
< Tarinaky>
Ahh. Yeah.
22:03
< Tarinaky>
But it does outperform a placebo.
22:03
< gnolam>
(* usual caveats about non-zero risks and opportunity costs apply)
22:03
<&McMartin>
gnolam: My understanding was that it did well enough that you could use it as an operating anaesthetic.
22:03
<&McMartin>
A la hypnosis
22:03
< gnolam>
No.
22:03
<&McMartin>
But I may have a hash collision *with* hypnosis
22:03
< gnolam>
I believe so.
22:05
< gnolam>
Tarinaky: a placebo doesn't have to be a pill. Any kind of sham treatment's covered.
22:05
<&McMartin>
Not to be confused with meta-placebo studies, which are wacky and terrifying.
22:05
<&McMartin>
(That is, some sham treatments seem to work better than other ones)
22:05
< Tarinaky>
gnolam: No. But a sugar pill is easier to control for.
22:06
< Tarinaky>
"Chronic low-level pain? Great, half of you take this pill and half of you lie down."
22:06
< Tarinaky>
"Now, hands up if you've had a reduction in pain."
22:06
< Tarinaky>
:p
22:13 Derakon[AFK] is now known as Derakon
22:22 iospace is now known as io|gone
22:46 celticminstrel [celticminst@Nightstar-5d22ab1d.cable.rogers.com] has quit [[NS] Quit: KABOOM! It seems that I have exploded. Please wait while I reinstall the universe.]
23:39 himi-cat [fow035@D741F1.243F35.CADC30.81D435] has joined #code
23:55 celticminstrel [celticminst@Nightstar-05d23b97.cable.rogers.com] has joined #code
--- Log closed Tue Jun 26 00:00:18 2012
code logs -> 2012 -> Mon, 25 Jun 2012< code.20120624.log - code.20120626.log >

[ Latest log file ]