#ot1-perplexing-regexing

1 messages · Page 577 of 1

inland wolf
#

ive always hated the animation for that

latent scaffold
#

kinda strange ngl

#

tbh I think I hate it

clear acorn
#

You're a power ranger did u ever fight the ever fight the giant villains

wheat lynx
#

I've tried it before, as it seems like a good idea, but i've always ended up changing it back because it's annoyed me

clear acorn
latent scaffold
#

okay but wait... is wookie a wookie or a power ranger

wheat lynx
#

both

shrewd prawn
wheat lynx
#

a wookie in a power ranger suit

#

tight fit but it works

latent scaffold
#

Alright, writing that down

shrewd prawn
#

lol

rough sapphire
#

comfort was never a priority of power rangers

latent scaffold
#

What is your mother-in-law's maiden name?

acoustic moss
#

red ranger by day, chewbacca by night

wheat lynx
latent scaffold
#

yep

#

I mean no

#

obviously not

rough sapphire
#

cyph sus

clear acorn
#

Out of the power rangers thingy my fav was ryukendo and the ones with a r in its name

latent scaffold
#

it's for um my um school survey obviously

#

because I'm obviously in school

acoustic moss
#

sounds legit

rough sapphire
#

yeah true.

latent scaffold
#

It's a study of the correlation between wookie-ness and mother-in-law maiden names

#

oh and also to encrypt your data we request the 3 numbers in the back of your credit card

rough sapphire
#

also for study purpose

latent scaffold
#

you gain extra security for providing your SSN, as well

#

that's why it's called your Social Security Number

last mantle
rough sapphire
#

tho you must contact vivek, he has this info about wookie.

latent scaffold
#

I also have info on Vivek

near bolt
#

in sql, i don't get why creating an index on the table will make the search faster

#

eg. sqlite> CREATE INDEX title_index ON shows (title);

#

Creating an index takes some time, but afterwards we can run queries much more quickly.

#
    ...> JOIN stars ON people.id = stars.person_id
    ...> JOIN shows ON stars.show_id = shows.id
    ...> WHERE name = "Steve Carell";
...
The Morning Show
LA Times: the Envelope```
inland wolf
#

@near bolt arent indexes in books faster than looking through each page?

near bolt
#

but i find it weird cuz we create the indexes

#

but afterwards we don't use it in the command for sqlite

inland wolf
#

the index is present

#

so when u query it will be used

rough sapphire
#

yeah can say. sql uses B/B+ trees IIRC, which kinda need some index reference to skip sequence instead of checking every row.

near bolt
#

oh i see okay thanks

rough sapphire
#

also the ref of book is very much relatable. +1 to that.

jaunty blade
scarlet wind
#

so pro

#

wasted my time trying to figure out why it's not compiling

#

-_-

shrewd prawn
#

why, is your variable, named Main.Java

#

oh wait, no, im guessing thats its location?

#

but yeah, the j should be lower case, right

scarlet wind
shrewd prawn
#

weird

scarlet wind
#

Main.java is file name which is inside variables folder

shrewd prawn
#

ahh i see

#

i thought the variables folder was like a debug tag of your variables

scarlet wind
frozen coral
#

Java sadge

inland wolf
#

java-pain

shrewd prawn
#

why do you hvae so many Mains

scarlet wind
scarlet wind
shrewd prawn
#

its... so painful

scarlet wind
#

Main.class is the compiled one

#

it's literally the convention

graceful basin
#

You could in theory just have multiple main classes not called main in the same package

scarlet wind
frozen coral
#
enum H{H;{System.out.print("Hello, World!");System.exit(0);}}
#

my favourite snippet of java

scarlet wind
#

;(

latent scaffold
#

:faint:

#

How 2 convert Java programmers to Kotlin programmers 101

frozen coral
#

There's also this one ```c
class X{static void Main(){if(System.Console.Write("Hello, World!")is X){}}}

latent scaffold
#

I need a faint emoji ;[

shrewd prawn
#

why the one liners NOOO

frozen coral
#

that's C though lol

scarlet wind
#

why gib more pain

#

lol

frozen coral
#

Talking about it here a few days ago

acoustic moss
#

C has class pithink

#

dym C#

latent scaffold
#

wait C doesn't have classes

#

does it!?

frozen coral
scarlet wind
frozen coral
#

Hemlock's favourite lang

graceful basin
#

Didn't the enum thing get fixed

scarlet wind
latent scaffold
scarlet wind
latent scaffold
#

tbh idk why I'm stressed about sleeping early

#

I forget it's summer

rough sapphire
#

for mbappe its sommer

prisma agate
#

Almost dead

jaunty blade
#

Then Charge It

spare lance
wraith hound
#

I signed up right when I heard about it

#

And got the email last night

livid citrus
#

@rough sapphire I would like to discuss php 😉

tardy rain
#

Why tho

livid citrus
#

Why not?

tardy rain
#

Discussion about PHP usually devolves into language bashing

livid citrus
#

I don't want to bash 2 languages, php is just not my cup of tea

livid citrus
#

At least because there's a lot of deprecated stuff in php

#

No generics 🤔

#

On it's own php is hard to write something good in, simply because of it's standard library

wraith hound
#

I dislike PHP syntax, but that's a me thing

livid citrus
#

Syntax is subjective thing but i dislike it too

#

Also just an ability to use variable values as variable names ($$)

#

aka dynamic variables or something

#

There are some good frameworks like Laravel, but they're not suited for api's, at least out of the box.

tardy rain
livid citrus
#

I'm aware

tardy rain
#

But not as cool looking

livid citrus
#

That's not a language a new developer would like to write with anyway

tardy rain
#

Why not, whole bunch of jobs for laravel, wordpress plugins, etc

#

Its an easy way into webdev

graceful basin
#

wordpress runs close to a majority of the internet, no?

rough sapphire
#

transcript,

son: "moms i would replace my mom with"
mom: "why would you want to replace me?"
son: turns to next page "1. No One"
mom: "whats on the next screen?"
son: turns to next page "2. Deez"
mom: "these? these what?"
son: DEEZ NUTS trollface trollface trollface

last mantle
#

oh no

edgy crest
silent plaza
#

python ded

acoustic moss
#

F

#

don't look so operational to me

silent plaza
acoustic moss
#

yeah

lunar crescent
#

yeah no, the cdns down, nvm its back

acoustic moss
#

ah good

silent plaza
#

oh ah

#

came back now anyways

acoustic moss
#

oh yay its back

acoustic moss
silent plaza
#

after a long time u goto the docs just to see that its not working oof <-- me

lunar crescent
#

now the backend is down

clear plume
#

Tl;dr python bad, go use rust

#

/s

acoustic moss
#

heresy

edgy crest
near bolt
#

in sql, can I do operations with the data i get from the function
eg. from SELECT AVG(energy) FROM songs;, I get 0.659 but I want to "print out" 0.659/10

inland wolf
#

try AVG(energy)/10

near bolt
#

yup it works thanks

inland wolf
#

lol

clear plume
#

I'm on my third cortadito of the hour, tonight should be fun.

tender smelt
#

anyone played gunner heat pc?

calm dawn
#

I feel like main blocks are a little tiny for the size of some programs...
Nearly 1000 lines spread over 6 files and the main block is only 4 lines <_<

modern void
#

what is a flat file?

clear plume
#

Cuban crack

#

Crazy strong coffee

last mantle
#

hmm

inland wolf
#

bruh

pure merlin
#

just a simple question
flutter or react-native
im getting into mobile development and im fairly new to dart, whereas im fairly experience in js but I want to work with regard to the future so what should I learn?

last mantle
#

you can choose any

edgy crest
#

@versed saffron do you know how i can pass an array of vec2s to a frag shader

#

i am like trying to add a trail to the mouse, and i want it to be so like the last 20 mouse positions be colored by the frag shader

versed saffron
#

uh I dont think you'd use a shader for that

#

is the trail just a copy of the cursor? or a different sprite

edgy crest
#

PepeCry aight

#

nah just a pixel color gradient ig

#

i thought shaders would be more suitable since they allow to color each pixel individually

versed saffron
#

well I really don't have any idea as to how to approach that but ill do some digging
regardless, you'd need to define the trail's vertex and frag shaders and treat it as a different sprite
if you're going for a rainbow-esque trail you can probably treat the sprite as a rectangle + lerp from red->purple from the colours and only draw what you want the shape to be
but again, no idea how you'd do that

edgy crest
#

nah i just want a one color trail

#

but the alpha is decreasing based on its index

#

the array is basically a queue

#

so it would be handy if i can pass the array to the shader while computing its values in the main program

versed saffron
#

the gpu does do some inference with the data it gets too:

// main.cpp
float vertices[] = {
    // positions         // colors
     0.5f, -0.5f, 0.0f,  1.0f, 0.0f, 0.0f,   // bottom right
    -0.5f, -0.5f, 0.0f,  0.0f, 1.0f, 0.0f,   // bottom left
     0.0f,  0.5f, 0.0f,  0.0f, 0.0f, 1.0f    // top 
};    

// vert.shader
#version 330 core
layout (location = 0) in vec3 aPos;   // the position variable has attribute position 0
layout (location = 1) in vec3 aColor; // the color variable has attribute position 1
  
out vec3 ourColor; // output a color to the fragment shader

void main()
{
    gl_Position = vec4(aPos, 1.0);
    ourColor = aColor; // set ourColor to the input color we got from the vertex data
}       

// frag.shader
#version 330 core
out vec4 FragColor;  
in vec3 ourColor;
  
void main()
{
    FragColor = vec4(ourColor, 1.0);
}```
produces this
versed saffron
edgy crest
#

nope.. but ill check

edgy crest
#

i think it uses miniquad which is based on crayon which uses opengl backends

versed saffron
#

miniquad

#

i stg

#

we don't need more abstraction :(

acoustic moss
#

you say that in a python server

versed saffron
#

shut.

acoustic moss
versed saffron
#

do you know if you have access to gl if that is the api?

versed saffron
#

fml that aint it

#

can you access miniquad's api?

edgy crest
#

yeh

#

699 stars nice

inland wolf
#

truly

acoustic moss
#

nicw

#

*e

latent scaffold
#

nicwe

versed saffron
#

ᵒʰⁿᵒˢᵒᵐᵉᵒⁿᵉʲᵘˢᵗˢᵗᵃʳᵉᵈᶦᵗʷʰᵒʷᵒᵘˡᵈᵈᵒᵗʰᵃᵗ

latent scaffold
#

why

acoustic moss
#

noooooo

#

ok, we have to make 2 forks

latent scaffold
#

⁰¹²³

#

okay I got too lazy for the rest

acoustic moss
#

wtf how many unicode characters are numeric!?

#
In [8]: len(list(filter(str.isnumeric, map(chr, range(100000)))))
Out[8]: 1563
#

yes i have list(filter(map()))
cry about it

inland wolf
#

hmm

#

are tehre only 100000 unicode characters

edgy crest
#

who dares to do this

inland wolf
#

ur about 4 minutes too late

acoustic moss
inland wolf
#

lol

acoustic moss
#
In [21]: len(list(filter(str.isnumeric, map(chr, range(1114112)))))
Out[21]: 1862
inland wolf
#

yes

acoustic moss
#
In [21]: len(list(filter(str.isnumeric, map(chr, range(1114112)))))
Out[21]: 1862

In [22]: len(list(filter(str.isdigit, map(chr, range(1114112)))))
Out[22]: 778

In [23]: len(list(filter(str.isdecimal, map(chr, range(1114112)))))
Out[23]: 650

hmmm

versed saffron
versed saffron
inland wolf
#

ikr

versed saffron
#

How’s the coord sys set up?

edgy crest
#

top left is 0, 0

#

though glsl is 0, 0 on bottom left

#

i can also pass window size through a uniform and subtract the y value

#

so that should not be a prob

#

but how do i use this QuadGl.geometry

versed saffron
#

uhh

edgy crest
versed saffron
#

wow

edgy crest
#

nooooo

#

where da long message

versed saffron
#

im sorry, I barely know what im doing in gl and now ive gotta figure it out in a lang I have no knowledge in?

#

and now ur harassing me ;-;

edgy crest
#

what did i do

versed saffron
inland wolf
versed saffron
#
let quad = QuadGl.new(ctx);

// set geometry
quad.geometry(vertices, indices);

// if you want shaders (?)
let result = quad.make_pipeline(ctx, frag, vert, params); // returns Result<GlPipeline, ShaderError>, idk what that means

// if you want a texture
quad.texture(Texture2D_instance);

// set draw mode
quad.draw_mode([Triangles or Lines]);

// draw it
quad.draw(ctx);```
versed saffron
edgy crest
#

oh but what does set geometry mean

acoustic moss
#

it sets the geometry

versed saffron
#

^^

edgy crest
#

geometry of what

inland wolf
versed saffron
#

give me like 5 mins while I type this out

#

ok so if I want to draw a triangle, I need 3 vertices

float vertices[] = {
    -0.5f, -0.5f, 0.0f,
     0.5f, -0.5f, 0.0f,
     0.0f,  0.5f, 0.0f
};```
those refer to the x, y and z coords but because it's 2d, the z can be 0. (I think `geometry` can accept just the x, y but idk what `[f32; 2]` means)

You then need to tell gl which order you want to draw those vertices with the indices:
 ```cpp
uint_32 indices[] = {0, 1, 2};

the need for indices becomes more apparent when you draw more complex shapes like a square, gl can only either draw lines or triangles (or points), so each sprite you make has to use those shapes

float vertices[] = {
     0.5f,  0.5f, 0.0f,  // top right
     0.5f, -0.5f, 0.0f,  // bottom right
    -0.5f, -0.5f, 0.0f,  // bottom left
    -0.5f,  0.5f, 0.0f   // top left 
};
unsigned int indices[] = {
    0, 1, 3,   // first triangle
    1, 2, 3    // second triangle
};```
indices allow you to reuse vertices already defined instead of having to write out all 6 of them (as 2 vertices per triangle are the same as the other)
#

the typehint for vertices is &[impl Into<([f32; 3], [f32; 2], [f32; 4])> + Copy] so im assuming that means an array of arrays of either 2, 3 or 4 (?!?) elements?

edgy crest
#

yeh impl Into means that whatever you pass can be converted to an array of either 3 floats, 2 floats or 4 floats

#

plus it also needs it to be copyable

versed saffron
#

ah ok

edgy crest
#

so i need array of array of 2 floats

versed saffron
#

there's also some other stuff included with QuadGl but idk if you'll need to use it

#

yes

edgy crest
#

but the thing is can i take control of those vertices myself

#

like i dont want them to draw shapes

versed saffron
#

well they're still going to draw triangles

edgy crest
#

aw

versed saffron
#

but you can choose how the triangles go together

#

that's how blender models work (sort of)

edgy crest
#

hmm, how would i use this though, i need to draw a line thinkies

versed saffron
#

well a line's just a long, thin rectangle is it not?

edgy crest
#

then that means

#

its all triangles

versed saffron
#

always has been 🔫

edgy crest
quick ledge
#

so a line is a rectangle with 0 width and infinite length

versed saffron
#

well a width of 1 pixel in this context

edgy crest
#

is really small

#

ye

versed saffron
#

idk where you got infinite length from

quick ledge
#

get out of here with your fake lines

#

a line has infinite length

#

a line segment has finite length

last mantle
#

yes

versed saffron
#

it doesn't look like there's any way to draw curves so if you wanted that you'd have to implement your own bezier curve algorithm

edgy crest
#

i know nothing about curves except that they are curves

versed saffron
#

nice embed

#

there's other types of curves too but idk anything about them

#

but it's basically just a summation, the higher your limit is, the smoother your curve gets + the more lines you have to draw

#

so it's a bit of a trade off between precision + performance

edgy crest
#

hmm

acoustic moss
#

wait but if a triangle is made of lines and lines are made of triangles

edgy crest
#

oh no

versed saffron
#

its all just triangles

#

circles?
triangles

#

points?
triangles

edgy crest
#

triangles?

#

triangles

versed saffron
#

hypersphere?
triangles

#

on what

edgy crest
#

3d models are triangles

#

marching cubes

versed saffron
#

ah ya it's hella important with 3d rendering

#

no, no cubes ;-;

edgy crest
#

marching cubes

#

are traignes

#

inside cubes

versed saffron
#

I mean, it's also just a useful equation

#

the triangle part is really just a visualization

#

but again

#

it's all triangles

#

:O

edgy crest
#

its all electricity

versed saffron
#

shit I forgot to ping jack today

edgy crest
#

what for

versed saffron
#

to ask them about pyo3

edgy crest
#

oh

versed saffron
#

again

edgy crest
#

you know ill go check it out and tell you how it is

versed saffron
#

sweet, im still gonna harass jack tho 😄

#

3b1b does it soooo well

edgy crest
versed saffron
#

where'd you get that from

edgy crest
#

mathematics server

versed saffron
#

if he straight up said he was god, i wouldnt blink

#

ah

olive furnace
#

3b1b's videos on Calculus taught me almost my entire calc class over the summer :0

#

There's gotta be more high-end stuff for math tbh

versed saffron
#

and not the khan academy shit

#

if I wanted to listen to a monotone lecture, i'd be going back to school next year

versed saffron
#

@edgy crest hows it coming along

topaz aurora
#

Is FP 'better' than OOP
@quiet tusk Continuing this from yesterday-ish

It really depends on who you ask there's a lot of memery between the two schools but more often than not practices in one is adopted in the other.

Again, it's really just about what abstractions you like better for building your program, OOP pretty much has the foothold in the industry as a whole but recent trends start to show FP and FP-like languages rising in popularity to try and stay away from billion-dollar mistakes like Java and JS

fallen sparrow
#

There's no compulsory FP courses where I'm studying, and only one at my previous uni... I wonder when it'll really catch on in industry if it's barely a thing in universities.

wheat lynx
#

fingers crossed

latent scaffold
#

hahaha me too

#

GitHub Actions... man

wheat lynx
#

IT WORKED!!!

edgy crest
#

i was wondering how would i layout the rectangles

#

and the triangles for the rectangles

versed saffron
#

Rip

#

What’re you going for?

edgy crest
#

a trail which just like

#

follows teh mouse

#

thought it would be as simple as just coloring the pixels of the mouse...

#

😢

versed saffron
#

Can you do like a paint sketch rq

edgy crest
#

sure

#

actually like you know those games like

#

osu

#

theres some trail following mouse

versed saffron
#

Idk that sounds kinda familiar

#

I think I’ve only got like 10 days of playtime tho

edgy crest
#

like if i moved my mouse from pos 1 to pos 2

#

it like interpolates between that

versed saffron
#

Ok so scratch the custom shapes, I’ve got an idea of what to do

edgy crest
#

and draws a curve like thing

#

o

versed saffron
#

I’m not sure of the implementation, but the way osu works is you have 1 (or 2) texture(s) that you instance at the mouse pos

#

Stick it in a container and after a certain amount of time/distance/etc, remove it

#

And just loop over that container in your draw loop

edgy crest
#

what do you mean by container

versed saffron
#

So you could just do that but with like circles

edgy crest
#

array?

versed saffron
#

Array, list, spritelist , whatever

#

You might get some form of optimization + cleaner code if you create your own container

edgy crest
#

wait i found something with what i want

#

sending link

#

i want something exactly like this

#

the mosue trail

versed saffron
#

I wasn’t expecting that to work so well on mobile lmao

rough sapphire
#

which tech?

#

its kinda handy on canvas(html, js)

edgy crest
#

i know js has some feature for that

rough sapphire
#

i mean initially one can just start about just drawing the dots wherever mouse goes, then a lil bit of json array thingy.

versed saffron
#

So if you wanted just a line the thickness of a pixel you could just record mouse coords + delete them after a period

edgy crest
#

unrelated but yeah B)

versed saffron
#

If not do the same with shapes/a texture

edgy crest
#

like i was doing that from the start

#

but didnt know how to draw

versed saffron
#

draw them first then draw whatever else you want

edgy crest
#

yes but

#

how draw

versed saffron
#

quad

rough sapphire
#

you can draw dots right?

edgy crest
#

hmm

rough sapphire
#

so, i mean where you stuck?

edgy crest
#

what if the mouse moves

#

a lot in just one frame

versed saffron
#

you'll always be dependent on your framerate

edgy crest
#

60, i cant control it

#

its dependent on the pc for macroquad no way of control

versed saffron
#

what the actual heck

edgy crest
#

ye

versed saffron
#

set_target_fps

edgy crest
#

does not work

versed saffron
#

it's gotta

edgy crest
versed saffron
#

wtf so they just capped it at 60?

edgy crest
#

no

#

its pc dependent

versed saffron
#

ok but regardless there shouldn't be a cap

edgy crest
#

if you got good gpu it could go real fast

#

yes no cap

versed saffron
#

is it because of vsync?

edgy crest
#

afaik

#

mahbe, idk much about this stuff

versed saffron
#

what's your monitors refresh rate

edgy crest
#

60

versed saffron
#

..

edgy crest
#

wot

versed saffron
#

there must be vsync then

#

vsync sync's your frames to your refresh rate

edgy crest
#

o

#

hmm okay so ill just draw 1 pixel radius circles on mouse position and remove over time

#

but can i use shaders for something here

versed saffron
#

you don't need to, it'll just overly complicate it

edgy crest
#

yes

#

:^)

#

i want to overly complicate it

#

like, this is not for some project

#

i was just playing around

versed saffron
#

I mean like stupid overly complicate it, iow idk how you'd accomplish it with this level of abstraction

edgy crest
#

would be a bummer if i cant get the most out of it.. but for now ill just do this much

versed saffron
#

it might be miniquad messing around with it too

versed saffron
#

id be 100% down to help work on smthing like that, my shader knowledge is non-existant

edgy crest
versed saffron
#

he do be walking

inland wolf
#

@edgy crest u want more frames?

edgy crest
#

does 100% down mean not interested or very interested

edgy crest
versed saffron
#

look at this graph

#

uber interested

inland wolf
versed saffron
#

i stg if you send a pic of a picture frame im gonna cry

edgy crest
#

picture of a picture frame having a picture of a picture frame, infinite frames!!!

inland wolf
#

no i was just asking a question

versed saffron
#

oh ok good ty

inland wolf
#

👍

versed saffron
edgy crest
solemn leaf
#

reduce refresh rate

#

fps will reduce ez

edgy crest
#

why "reduce"

versed saffron
#

but that's less frames?

inland wolf
#

lol

#

its capped at 60 for me too

solemn leaf
#

limit

edgy crest
solemn leaf
#

i don't cap

versed saffron
#

the issue says limit but the response says the gpu drivers cap the fps which you can disable

inland wolf
versed saffron
#

vblank_mode=0 cargo run --release

edgy crest
#

thonky

edgy crest
versed saffron
#

idk probably not

edgy crest
#

aight ill try

versed saffron
#

it also looks like you can directly access the api:

let InternalGlContext { quad_context: ctx, ..} = unsafe { get_internal_gl() };

ctx.show_mouse(false);
ctx.set_cursor_grab(true);
// toggles mouse visability ```
#

I think it might just be a case of the implementation not being great, iirc opengl has the ability to toggle vsync but I can't find anything in macro/miniquad about it

#

also im a gamer

#

a god gamer

edgy crest
versed saffron
#

osu skills coming through 😄

inland wolf
#

what is this score

edgy crest
inland wolf
#

cool game

versed saffron
#

rip give me a sec

#

the whole html part of it is screwing me over a lot

#

it just sometimes doesn't get the dots

versed saffron
inland wolf
#

bruh

inland wolf
versed saffron
versed saffron
tranquil orchid
#

not bad

inland wolf
versed saffron
#

oh right before I forget

#

@tranquil orchid

#

rust?

inland wolf
#

the trick is to not hit the red!!

versed saffron
#

kinda hard when they keep spawning in the area I just covered

inland wolf
#

ikr

versed saffron
#

like some sort of sanity check would've made this game soooo much better

#
  • don't let them be captured if they haven't spawned in fully
  • only capture them once it's been filled in and stop capturing immediately
#

bam AAA game

latent scaffold
inland wolf
#

cypherials been doing this for the past hour and he finally got a highscore

latent scaffold
#

doing what

#

oh

#

uh no I just tried it out

#

that was my second attempt

inland wolf
#

lol

#

tis a joke bro

latent scaffold
#

omg this game is stressful

inland wolf
#

ikr

inland wolf
#

lol

versed saffron
edgy crest
#

nop

#

lol

edgy crest
latent scaffold
#

:|

inland wolf
#

bruh

#

lol

versed saffron
#

bruh if I could stop randomly dying that'd be great

edgy crest
#

you have a health bar

fallen sparrow
#

I tried it on a laptop touchpad and it was a bad idea

edgy crest
#

rip

latent scaffold
#

I just discovered

#

this game is a little bit broken

latent scaffold
versed saffron
edgy crest
#

first that overheats my laptop

#

second, the trails still have a lot of space between them so it looks bad

#

looks like i need to do slerp but idk how to

versed saffron
#

what's your fps tho

edgy crest
#

uh didnt see

versed saffron
#

i should probably go to bed, but if you want, send me the code and ill set rust up and take a look when I get up

edgy crest
#

120-150

versed saffron
#

oh ok well at least that fixed something 😄

#

maybe check your cpu load too, that could be causing the studdering

edgy crest
#

ye its taking cpu

#

so ill just let it be 60

versed saffron
#

if not it could be an implementation thing, im really really hoping they're using a double buffer cause if not that's a massive issue

edgy crest
#

i mean i dont really want high fps rn

#

so 60 is okeyish

versed saffron
#

but you should have the option to

#

even pygame can reliably run higher

latent scaffold
#

wot you're refresh rate

edgy crest
#

60

latent scaffold
#

wtf my grammar

#

oh yeah. stay at 60

#

no point in going higher than 60 if your refresh rate is only 60 Mhz

versed saffron
#

oh ya ig you could get tearing

#

hmm

latent scaffold
#

wtf

#

I left that game in the background

#

Someone please tell me why that thing takes like 30% of my CPU

tranquil orchid
#

👀

#

Holdon I still got it open somewhere lemme check the task manager

#

See how much bitcoin it's mining in the background

latent scaffold
#

hahaha

#

I was just wondering why my fans were going crazy

#

I checked task manager and Microsoft Edge was taking 20-30 % CPU

tranquil orchid
#

Hmmm, it's doing nothing on mine

latent scaffold
#

rather... "System Monitor"

edgy crest
latent scaffold
latent scaffold
tranquil orchid
#

Perhaps, lemme see what it's like when open

latent scaffold
#

very nice

versed saffron
#

that's...

#

pretty?

tranquil orchid
#

facebook, facebook everywhere

#

I'm just trying to game

#

Why do you want to track me facebook

latent scaffold
#

lmao

#

what is that

tranquil orchid
#

Firefox task manager

#

facebook and twitter want to track me while I game

latent scaffold
#

that's a bad screenshot

edgy crest
latent scaffold
#

Ryzen 7 4800H

edgy crest
#

nevermind

latent scaffold
#

lol

#

btw the average CPU usage for Edge for me is usually 0.1%

#

actually... more like 0.0%

tranquil orchid
#

Why is facebook tracking me on an article for neural nets as well

#

what

latent scaffold
#

Do you not have Privacy Badger? D:

tranquil orchid
#

Dunno what that is, firefox's default stuff is good enough for me

latent scaffold
#

It blocks trackers

#

among other things, sometimes

#

works great with uBlock

tranquil orchid
#

The trackers can learn neural net math with me, they'll suffer

latent scaffold
#

I believe Privacy Badger actually uses ML

#

if not, it uses something for "learning"

#

"Privacy Badger automatically learns to block invisible trackers."

edgy crest
#

wonder how bad would it be to learn ML and do it all in rust without any ML libs except for math calcs

tranquil orchid
#

Well

#

What if I were to tell you

#

That's the plan

latent scaffold
#

:faint:

edgy crest
#

lol

#

nalgebra moment

tranquil orchid
#

I'm gonna try make the neural net in rust

#

for the speed

versed saffron
#

@edgy crest I think I may have found the problem, and there's a reaallly good chance it's a massive issue with the implementation. I can't seem to find anything in macro or miniquad about swapping the buffers which is pretty necessary to run anything more complex than a ui. There's also this https://github.com/not-fl3/macroquad/issues/52#issuecomment-832030762 which sort of confirms that it's garbage.

tranquil orchid
#

The rest of the stuff can stay in Python

versed saffron
#

ᵖʸᵒ³?

tranquil orchid
#

Everything I previously had in this project worked fine, except the neural net (mostly), so I'd be remaking it anyway

tranquil orchid
graceful basin
#

I once tried to make a neural net in scheme

graceful basin
#

but I am pretty bad at that kind of math, so I couldn't get it done

tranquil orchid
#

I'm not really sure what happened to my net

#

When I tested it, it was perfect

#

Then I tested it again like a week later

#

It was terrible

#

So clearly I touched something somewhere I shouldn't have

#

But I could never find what it was

edgy crest
#

it went the wrong route while you were gone

tranquil orchid
#

So, from the top, in rust

edgy crest
#

learn parenting jack

tranquil orchid
#

I mean, it is being used in reinforcement learning, so that statement can be used literally

latent scaffold
#

Jack is a parent

#

got it

tranquil orchid
#

well

#

no

latent scaffold
#

woah

#

I saw absolutely nothing

versed saffron
#

hm?

tranquil orchid
#

Wot

versed saffron
#

bruh

latent scaffold
#

that's awkward

#

anyways

edgy crest
#

@versed saffron btww

versed saffron
#

huh what did you do?

inland wolf
edgy crest
#

|| its just line segments bro||

versed saffron
#

oh ok I was wondering if it looked choppy because of the recording fps lol

edgy crest
versed saffron
#

im still not convinced it's a shitty wrapper tho

tranquil orchid
#

@edgy crest What do you use for the graphics?

edgy crest
#

macroquad

tranquil orchid
#

Any good?

edgy crest
#

yes it nice

#

imo

#

you can also use rust-sfml and sdl but i like macroquad because its easily installable and you can also compile to wasm with just one command

versed saffron
#

the whole not being able to disable vsync isn't nice tho

edgy crest
#

man it isnt that bad

versed saffron
#

also not being able to draw single points

edgy crest
#

draw_circle iwth radius 1?

versed saffron
#

ig you could just make a 1x1 rect

#

or that

#

either way it's a hack

edgy crest
versed saffron
edgy crest
#

whats MacOs ?

#

i only know linux windows and web

#

:p

versed saffron
#

you had me worried for a sec

#

there's also the whole not being able to adjust the swap interval

edgy crest
#

heh anyways idc bout mac

#

idc bout that either

#

i am not making

#

games

versed saffron
#

it still should be able to do it tho

#

it's a pretty basic gl thing

#

which like

#

why isn't that implemented

#

idk it's not terrible but for being 16 months old there's a bit of basic stuff missing that should've been a priority

rough sapphire
#

@viral parrot HOW ARE YOU?

edgy crest
#

though i might take a look at wgpu

versed saffron
#

i've got a game-dev friend who's super into rust graphics, imma try to get his opinion on it

edgy crest
#

also ask him what he uses

#

also whats vulkan

versed saffron
#

ik he mentioned Amethyst and Bevy (apparently Bevy isn't really well documented tho) but I haven't had a chance to look at them

latent scaffold
#

It's a graphics API

#

like openGL or Direct3D

versed saffron
#

a low level api

#

it's not like opengl at all

latent scaffold
#

wot

edgy crest
#

aw not opengl

versed saffron
#

you have to build your own pipeline for starters

latent scaffold
#

I didn't say it's like openGL

edgy crest
#

is vulkan better

latent scaffold
#

I mean not in that regard

versed saffron
#

like openGL

#

:)

latent scaffold
latent scaffold
versed saffron
#

it lets you customize basically the whole rendering process

latent scaffold
#

I can say "Python is a programming language, like Rust"

#

because both are programming languages, even though they can be wildly different

versed saffron
#

i'd argue it's more of a rendering api like DX but you're not wrong

#

but anyways you have to build your own pipeline meaning, compiling shaders, sending objects through the shaders, handling the buffers (writing the output of the data to them), sending the buffers to the gpu, along with anything else you need along the process

#

and that's on top of getting your window + events working + sounds + an entity component system + physics engine

#

tldr it's an massive amount of work but the pay off is you control every step of the process

edgy crest
#

153 lines to crate a triangle

#

guess its lower than i wnat

versed saffron
#

there's usually a lot of buffers involved for performance

#

you dont really want to be iterating over every single pixel and checking if it's updated

#

also error handling is a pain with graphics

graceful basin
#

I like bevy, but I do prefer this macroquad for just drawing things

versed saffron
#

Amethyst looks pretty decent actually

graceful basin
#

but yeah, for a larger project, I would not use it

#

I find bevy nicer, it has a lot less complexity

versed saffron
#

I kinda like complexity tho 😄

graceful basin
#

if you do, you will love amethyst

#

I just decided to not get bogged down by abstractions when all I wanted to do is rotate a camera around a sphere

versed saffron
#

ya to be fair I got lost in opengl pretty quick

graceful basin
#

I got further than I thought in openGL, but I can't imagine doing a project in raw openGL that wasn't about using openGL

versed saffron
#

I made a triangle with a spinning colour and moved on to making a framework which was a massive mistake

#

ya idk I can't say I love it

#

I've got a few projects in mind now tho so I think I just need to find an api/lang that im comfortable with and plan everything out

#

idk I definitely have an issue staying committed to projects

edgy crest
graceful basin
#

pretty light

#

more than macroquad

edgy crest
#

cool

#

ye thats expected

austere forum
calm dawn
#

I tried OpenGL with Python last year

#

I would up finding one tutorial that actually used PyOpenGL and could not understand it at all.

latent scaffold
#

OpenGL is confusing as fuck lmao

#

I remember I made a rotating cube that I really just ripped off of the internet

edgy crest
latent scaffold
#

absolutely mind boggling

edgy crest
#

wont a rotating cube just be a rotational matrix around the centroid for each vertex

#

@acoustic moss correct if wrong

acoustic moss
#

ok

edgy crest
latent scaffold
acoustic moss
#

here we go again

edgy crest
#

what does

#

tod mean

acoustic moss
#

tod

last mantle
#

tod

calm dawn
#

I sense irritation on hshyp's part...

last mantle
#

tod.

versed saffron
#

Toad

edgy crest
calm dawn
last mantle
#

explain

#

holup its not from this server

latent scaffold
#

um

#

these seem so mean out of context hahaha

inland wolf
#

lol

last mantle
#

doesn't matter, hsp is a meanie anyways

latent scaffold
#

I agree

acoustic moss
#

who's hsp

latent scaffold
#

good question

rich moon
#

someone ban hsp

acoustic moss
#

ikr

knotty palm
#

need help with making labels for my data because my creativity left me: I have one dataset that has results of some function fitting to some data and another dataset which does the same except some of the input data is weighted to zero (basically data[some time range] = 0). What would be 2 labels that distinguish them? I have "weight" and "zero weight" right now and that just doesn't do it 😄 I also thought of "no weight" and "zero weight" but that seems weird...

gritty zinc
#

filtered weight?

knotty palm
gritty zinc
#

just weight

knotty palm
#

but one of them doesn't have any weight applied to it, that's my issue 😄

gritty zinc
#

oh

#

fit, weighted (or weigthed fit)

#

of course, two words mean no dot access 😛

knotty palm
#

I like weighted fit, then the other would be unweighted fit?

#

I dont use dot access

#

its confusing

#

df.groupy().method().method().column.shape and I'm lost what is what

#

I prefer [] 🙂

edgy crest
#

@versed saffron i need to find out whats wrong here :<

#

uniform vec2 m_pos;
uniform vec2 res; 

void main() {
    vec2 st = m_pos / res;
    st.y = 1.0 - st.y;
    float dist = distance(gl_FragCoord.xy, st);
    vec4 col = vec4(0.0, 0.0, 0.0, 1.0);
    if (dist <= 0.01) {
        col.rgb = vec3(1.0);
        col.a = 1.0 - (dist * 50.0);
    }
    gl_FragColor = col;
}```
#

trying to make a circle around the mouse cursor

#

this should work right

versed saffron
#

vec2 st = m_pos / res; is that valid?

edgy crest
#

why should it not be

versed saffron
#

they're vectors?

edgy crest
#

yeh

versed saffron
#

idk if theres op overloading or not

edgy crest
#

shud i do .xy / .xy ?

versed saffron
#

also is this glsl?

edgy crest
#

yes

gritty zinc
#

I wouldn't be sure at all that elementwise division is defined for them

versed saffron
#

you have the shebang?

edgy crest
#

oh i didnt send the full shader

versed saffron
#

oh ok

edgy crest
#
#version 100
#ifdef GL_ES
precision mediump float;
#endif

uniform vec2 m_pos;
uniform vec2 res; 

void main() {
    vec2 st = m_pos / res;
    st.y = 1.0 - st.y;
    float dist = distance(gl_FragCoord.xy, st);
    vec4 col = vec4(0.0, 0.0, 0.0, 1.0);
    if (dist <= 0.01) {
        col.rgb = vec3(1.0);
        col.a = 1.0 - (dist * 50.0);
    }
    gl_FragColor = col;
}```
#

hmm im pretty sure / is supported because i have seen it on thebookofshaders

versed saffron
#
col.rgb = vec3(1.0);
col.a = 1.0 - (dist * 50.0);```
pretty sure that isn
#

't valid either

edgy crest
#

but

#

why

versed saffron
#

especially the .rgb

edgy crest
#

it is

#

.xyz and .rgb same

gritty zinc
#

huh, what's vec3(1.0) supposed to be

#

is that like a variadic constructor

edgy crest
#

1.0, 1.0, 1.0

gritty zinc
#

weird, okay

edgy crest
#

ok so division is valid fwiw

versed saffron
#
if (dist <= 0.01) {
  vec4 col = vec4(1.0, 1.0, 1.0, 1.0 - (dist * 50.0));
} else {
  vec4 col = vec4(0.0, 0.0, 0.0, 1.0);
}```
gritty zinc
#

hmm, I did want to play around with opengl for a while

#

guess now would be a good time

#

in Rust, of course

versed saffron
#

also this

distance(gl_FragCoord.xy, st);```
#

idek if you can unpack like that

edgy crest
#

unpack it like that

versed saffron
#

holllddddd up

#

why

#

why

#

are you using

#

version 1???

edgy crest
#

thats what macroquad supports

versed saffron
#

oh god whyyy

edgy crest
#

some compatibility reason idk why ask them

versed saffron
#

is there any way to get errors when you set the program

edgy crest
#

you do get compilation errors

versed saffron
#

cause ur glsl is gonna be kinda limited

edgy crest
#

for example syntax ones

#

and i did not get ayn

#

so

#

the syntax is all valid

versed saffron
#

@graceful basin you mentioned you've used macroquad, have you messed around with shaders in it?

#

im just very confused, this looks like a mess compared to what I've done

#

where are you getting gl_FragColor from?

edgy crest
#

its the color of the pixel

#

builtin

#

for shader

versed saffron
#

huh ya ive got no clue

#

have you tried using a higher version?

edgy crest
#

i am fairly certain this is not a problem of versions

#

hmm so apparently the if condition isnt even getting hit

versed saffron
#

what does distance do?

edgy crest
#

distance between

#

the vectors given

versed saffron
#

does it return the euclidean distance or a vec3?

edgy crest
#

hmm ill have to check

gritty zinc
#

that'd be pretty crazy if it's a vec3. Like, what'd that be, elementwise -?

versed saffron
#

¯_(ツ)_/¯

#

what version of gl are you using?

edgy crest
#

returns scalar

versed saffron
#

or being forced to use ig

edgy crest
#

100..?

#

oh

#

you mean opengl

#

3.1 or smth ig

versed saffron
#

yes

#

ok

#

so

#

that doesnt add up

#

I get it not supporting the latest version but it should at least run 3.3

edgy crest
#

wow ok so i got it to work now

#

gl_FragCoord is apparently not normalized

versed saffron
#

that's kinda counterintuitive?

edgy crest
#

wot

versed saffron
#

ig it kinda makes sense?

#

wait getting or setting pixels?

#

or both

edgy crest
versed saffron
#

huh

#

alright

edgy crest
#

uhhh so

#

now how do i

#

use built in functions for rendering of macroquad

#

and shaders to add effects on them

#

cause rn

#

only the shaders take effect

#

like things which i am drawing from rust

#

arent getting drawn

versed saffron
#

quad.make_pipeline(ctx, frag, vert, params);

edgy crest
versed saffron
#

im not sure if quad needs to be QuadGl or if it can be any geometry

#

either way you need to get the opengl context and idk how

#

I remember seeing something about using unsafe tho

edgy crest
#

same

#

ima go check out

versed saffron
#

let InternalGlContext { quad_context: ctx, ..} = unsafe { get_internal_gl() };

#

idk how tf that sets ctx as the context

#

some rust magic ig

#

alright cya

edgy crest
#

cya

rough sapphire
#

Anyone chess?

gritty zinc
#

master-tot
👀

gritty zinc
#

it's kinda like

let a = unsafe { get_internal_gl() };
let ctx = a.quad_context;
#

InternalGlContext { quad_context: ctx, ..} is the pattern we match against - so the field quad_context goes into ctx, and .. means the other fields are ignored.

inland wolf
#

that would be funny i think

gritty zinc
#

just spent some time debugging why my shader using a uniform wasn't working

#

of course, it was the C null-terminated strings...

#

wrong:
gl::GetUniformLocation(shader_program.id(), "triColor".as_ptr() as _)
right:

let unif_name = CString::new("triColor").unwrap();
gl::GetUniformLocation(shader_program.id(), unif_name.as_ptr() as _)
#

In reality the situation is too catastrophic, and it’s almost impossible to keep that initial goal of fixing driver errors. I have the feeling that some driver writers barely read the specifications, and the fact that online documentation (like docs.gl) is filled with mistakes doesn’t help.
(C) glium's author on OpenGL drivers
yikes

sullen condor
#

Whos that pokemon

#

Actvtee

#

Actuvutee

#

Actuvuty

#

WHY

#

Activity

modern haven
sullen condor
modern haven
#

oh fuck you got me, smh

viscid hemlock
#

Lmao

gritty zinc
misty dew
#

what is it

#

mm tasty

#

my friend once gave another friend his chips that he dropped in the dirt and called them salt and pepper chips

#

and he ate the whole bag

#

fun times

vapid nymph
#

Oh god. Lmao

#

I thought it was a raid

pseudo crystal
misty dew
#

nah he was fine

#

I had a few too and so was I

pseudo crystal
#

One time when I was younger I had a mischevious side and convinced my brother to drink this greenish water from a sandbox. Still feel bad about that one ngl

#

He never got sick but mannnn

misty dew
#

eww

#

how did you manage to convince him to do that

pseudo crystal
#

We said it was koolaid lol. I was in 3rd grade or so I think and he was 3 years younger

misty dew
#

'green koolaid! yum!'

pseudo crystal
#

Very long time ago from a galaxy...

misty dew
#

I sprayed sunscreen on bees and they stung my brother 😎

pseudo crystal
#

Exactly lol

misty dew
#

that one was an accident tho I was in like first grade

pseudo crystal
#

Dayum I feel worse for the bees

misty dew
#

mhm

pseudo crystal
#

Ah that's good at least it was accidental.

misty dew
#

yeah i dunno what I was even thinkin

#

'oh no, the bees are getting sunburned!'

pseudo crystal
#

Haha

#

Little kids are strange

#

I remember as a 3 or 4 yr old eating lots of newspaper and playdo

misty dew
#

yes

pseudo crystal
#

It's a miracle my stomach still functions

#

Honestly couldn't tell ya haha

misty dew
#

lots of kids ate paper in elementary school

#

and it always confused me why

#

now I realize those are the ones that did not do extremely well in school

pseudo crystal
#

I think it's just pure curiosity at the taboo nature

#

Tell a kid not to do something and it makes them really curious and want to do it haha

misty dew
#

true

pseudo crystal
#

Good ol reverse psychology

misty dew
#

'hey kid, eat this paper'

rough sapphire
#

I

modern haven
thick osprey
#

saddest commit of my day git commit -m "Add actual friends to the friends test :rooSad:"

tender smelt
#

i hate the -m flag

thick osprey
#

Why?

tender smelt
#

because it forces you to throw all the details into the title

#

just write a short title and put detail into the body

thick osprey
#

Oh. I can see that being an issue if someone were to try and put all the details in the title.

versed saffron
#

its nice for small commits tho

thick osprey
#

My titles are less than 72 characters anyway.

#
6311047 (HEAD -> main) Add actual friends to the friends test :rooSad:
ecffa58 (origin/main) Update with friend reference
81c6d00 Player friends
3451627 player friends model
b9ccb0f Pull models out of main files
b3379eb Remove reference to make in local setup
ce3629c Documentation
047ad5a logging cleanup
b41b6b2 Pull player data, restructure objects
2f92d0d recorded authuser tests
8f2282c recorded player class
d952099 Add vcrpy
cd43133 Refactor moving authuser into seperate object
13db793 lookup by uuid
23fceec Cleanup
9a2b5e1 uuid check
7e43776 Tweak tests, validate name
193c3fc player class init validation
80988cc create uuid validator
0b0660a pre-commit run
fa76cfd Remove main
21af6ff uuid lookup
28e885d get player
d963a3e Add secretbox requirement
851a9e6 Initial commit

smol

tender smelt
#

😢 they should be 50

#

oh well, i'm just being pedantic

#

but if you do have to add details, and you use -m then your commit message will look terrible

thick osprey
#

!e

print(len("Add actual friends to the friends test :rooSad:"))
royal lakeBOT
#

@thick osprey :white_check_mark: Your eval job has completed with return code 0.

47
thick osprey
#

nailed it

tender smelt
#

you know there are like, gitmojis?

#

idk if there's rooSad, but you can add emojis

thick osprey
tender smelt
#

sure, if they're tiny

thick osprey
#

and if they aren't tiny rooCry we're getting closer to an issue

tender smelt
#

it's a different "ideology" i guess ¯_(ツ)_/¯

thick osprey
#

Yup. 16 standards

tender smelt
#

some people like tiny commits (pad the stats smh), some like larger

thick osprey
#

This one just made me sigh because the reason the coverage was failing was not because coverage didn't know I was calling the factory, it was because I used my account in the test and I have no friends in that game darkoLUL

#

Had to add mock friendship

thick osprey
tender smelt
#

i'll often commit failed tries to solve a problem as documentation

thick osprey
#

But I work "next" to a teammate who will crunch eight hours of code and commit once EoD. Terrifies me, personally.

tender smelt
#

wild

thick osprey
#

Me: "What if the worst happens and you lose the work?"
Them: "Then they pay me another day to do it again shrug"

viscid hemlock
thick osprey
#

I actually wrote a script that removes them from my code pre-commit because I'd forget about them

#

So emoji references, yes. Actual unicode emojis, very seldom.

wraith hound
#

git commit -m "title" -m "description"

tender smelt
#

ok, but just use the editor at that point

tardy rain
#

And people shit on php not realising skynet will come from there

#

Php8 will now run on tensorflow

#

I wish i could complain about php more but where i live dotnet has all the fucking backend roles

#

Dotnet more like don'tnet

edgy crest
#

clik 2d visualization

versed saffron
#

actually pretty good

#

the collision is hella satisfying

edgy crest
#

theres 3d too