Search found 141 matches

by MasterLee
Wed Jun 14, 2017 8:53 am
Forum: Support and Development
Topic: Can I make & color-cycle a palettized image in memory ?
Replies: 7
Views: 1447

Re: Can I make & color-cycle a palettized image in memory ?

Löve has no nativ support for indexed images, so you are right you have to use an shader. That is definitely possible i did this before.
by MasterLee
Wed Jun 14, 2017 7:55 am
Forum: Support and Development
Topic: Music like in Nintendo games
Replies: 49
Views: 7220

Re: Music like in Nintendo games

PC Speaker has way better sound than you might expect
https://www.youtube.com/watch?v=J42iN3HMB68
Sadly there is no emulator capable to run those programs these days.
But maybe you are searching something like QBasic PLAY command.
by MasterLee
Tue Jun 13, 2017 8:10 am
Forum: Support and Development
Topic: Number displays incorrectly if the first digit is zero
Replies: 12
Views: 2142

Re: Number displays incorrectly if the first digit is zero

I not blocked you working solution. I just was curious about how renaming an variable could solve the problem.
As you changing:

Code: Select all

new = tostring(text)
to

Code: Select all

new = ('%010d'):format(text)
is joust enough. For formating 10 digit numbers.
by MasterLee
Tue Jun 13, 2017 7:35 am
Forum: Support and Development
Topic: Number displays incorrectly if the first digit is zero
Replies: 12
Views: 2142

Re: Number displays incorrectly if the first digit is zero

Just replace 'new' with the tostring(). phoneNumber = tostring(text) printedText = "(" .. phoneNumber:sub(1, 3) .. ") " .. phoneNumber:sub(4,6) .. "-" .. phoneNumber:sub(7,10) So actually instead of new = tostring(yours) text = "("..new:sub(1,3)..") "..new:sub(4,6).."-"..new:sub(7,10) he should wri...
by MasterLee
Sat Jun 10, 2017 2:42 pm
Forum: Support and Development
Topic: Can't run "Hello World" start project on Lubuntu 16.10
Replies: 2
Views: 689

Re: Can't run "Hello World" start project on Lubuntu 16.10

Currently i have no use for it but it is possible to rename the audio output of löve? Maybe into app name. Using Jack all apps are shown as alsoft Bildschirmfoto von »2017-06-10 16-32-22«.png Using PulseAudio all apps are shown as LÖVE Bildschirmfoto von »2017-06-10 16-36-10«.png Oh and another ques...
by MasterLee
Wed May 31, 2017 5:36 pm
Forum: Support and Development
Topic: Question about LuaJIT and FFI
Replies: 7
Views: 2063

Re: Question about LuaJIT and FFI

I have the following code: local ptr=ffi.cast('unsigned char*',data:getPointer()) for y=0,height-1 do for x=0,width-1 do local c=cells[y][x] ptr[0]=(c.n%16)*16 ptr=ptr+1 ptr[0]=math.floor(c.n/16)*16 ptr=ptr+1 ptr[0]=c.pal*8 ptr=ptr+1 ptr[0]=(c.xflip and 128 or 0)+(c.yflip and 64 or 0)+(c.dflip and 3...
by MasterLee
Wed May 31, 2017 9:11 am
Forum: Support and Development
Topic: Why is my program crashing?
Replies: 3
Views: 725

Re: Why is my program crashing?

There is no crash on my machine but i can't figure out what to do
by MasterLee
Tue May 30, 2017 5:34 pm
Forum: Support and Development
Topic: Access glEnable
Replies: 3
Views: 819

Re: Access glEnable

At the moment only to enable depth buffer

It seems i need glDisable also…
by MasterLee
Tue May 30, 2017 2:17 pm
Forum: Support and Development
Topic: Access glEnable
Replies: 3
Views: 819

Access glEnable

Simply question what is the best way to access glEnable. On my System the following works: ffi.cdef([[ typedef void (* PFNGLENABLEPROC) (int cap); void *SDL_GL_GetProcAddress(const char *proc); ]]) ffi.cast("PFNGLENABLEPROC",ffi.C.SDL_GL_GetProcAddress("glEnable"))(0x0B71) But is there an more elega...
by MasterLee
Mon May 29, 2017 6:13 pm
Forum: General
Topic: Texturing Meshes at an Angle
Replies: 17
Views: 5423

Re: Texturing Meshes at an Angle

Is it just me, or is something off about how it stretches things? Like the bottom is too stretched out. This is how it would look like in a proper perspective way (using pers.lua) It is just you: You have 16:9 i have 4:3 screen aspect ratio. Furthermore the upper part of your quad seems to have an ...