Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Jebbs

Pages: [1] 2 3 ... 24
Audio / Why InputSoundFile::openForWriting?
« on: August 05, 2017, 07:24:11 pm »
Why does openForWriting exist in the InputSoundFile header? It seems to be a leftover from SoundFile and has no definition in the cpp file. InputSoundFile should provide read-only access to the file anyway, so this is a weird method to have.

Can it be gotten rid of?

D / Re: Access Violation?
« on: October 13, 2016, 08:36:33 pm »
This does seem suspicious.

Can you give me a little more information? What platform are you on and what version of DSFML are you using? Anything else you might think is relevant would be useful too.

D / Re: DSFML Link/Build Issues
« on: October 04, 2016, 02:21:32 am »
So I rebuilt both for 64 bit this time, and implib is only for 32 bit, correct?

Correct. DMD's 32 bit linker(optlink) only accepts import libraries in a certain format, but 64 bit code uses a different linker. DMD uses the MSVC toolchain for 64 bit code, so make sure you're using the right compiler for that.

I'm confused on a few things though.
1. What to do with the "dsfmlc-XXX-2.dll"?
Link to them in the search directories or do they need to be placed in the /debug and /release dirs?

Those go in the same directory as your compiled .exe

2. The -I switch, isn't it redundant when you're already specifying the folders to refer to? Or is Code Blocks just not doing what it's supposed to, so you have to explicitly specify where to look?
Also what things am I exactly linking to?
The search directories to the src or the libraries or both?

Sorry if I wasn't clear. When I mentioned the -I switch, I was referring to it being used already (in your log) and that the -L switch was not being used even though you specified the directories in your linker settings. You'll need to manually add the linker options to include those directories to the searched list since Codeblocks doesn't appear to be doing it.

Also if you could be a little hand-holdy with the specifics that'd be nice.
I really need to learn more manual compiler stuff after this.

Have you taken a look at the building your first DSFML program tutorial? It should walk you through and explain a lot of things. If you need more help, let me know.

D / Re: DSFML Link/Build Issues
« on: October 01, 2016, 11:27:14 pm »
I've never used Codeblocks for a D project, but from your log it looks like the linker settings aren't being used.

Code: [Select]
dmd.exe  -O  -w   -IS:\DSFML-master\src -IS:\DSFMLC-master\build\src -c hello.d -ofobj\Release\hello.obj
dmd.exe bin\Release\Test.exe  obj\Release\hello.obj  dsfml-graphics.lib dsfml-window.lib dsfml-audio.lib dsfml-network.lib dsfml-system.lib
OPTLINK (R) for Win32  Release 8.00.17

The -I switch is for specifying where source code is, but there isn't any linker switches in there. You might try adding those in manually and see if that works. It should look like this: -L+lib/location/here. You'll need to link the DSFMLC libraries too in order to get everything to work correctly(you showed linking only to the DSFML libs in your steps).

Additionally,  it looks like you're producing 32 bit libs. I didn't see this in your steps, so don't forget to run implib(which I've bundled with DSFMLC) on your dll's to make import libraries optlink can use.

Let me know if you need any other help! And if anything is ever unclear, please shoot me an email so I can update the tutorials.

D / Re: DSFML compiling problem
« on: June 26, 2016, 07:19:21 am »
What command did you use to build?

This is because of the newest D compiler. They fixed a few long standing bugs, but it ended up breaking the way the import system was doing some things. What was actually happening is that it was using Object.toString() instead of dsfml.system.string.toString() because the compiler will search locally for symbols before checking any imported packages, even packages imported in the same scope. You just need to make sure you're a little more explicit with your calls where there is an ambiguity of function names. 

I put the fixes in the code just a couple of minutes ago, so once dub updates its DSFML package you should be good to go.

D / Re: Drawing text to a Image object
« on: November 21, 2015, 03:20:45 am »
I still haven't gotten my calendar to save as a picture file.  :( I've got bitmaps working.

http://dpaste.dzfl.pl/a1d1c54f019c (I cleaned out the code comments).

Would it be possible to open up an issue on github so that this doesn't get forgotten? I'm pretty overloaded at the moment and will be for a couple of weeks yet. Sorry for the delay. :(

The true solution would be a template based on std::is_integral and SFINAE or tag-dispatching. But I don't really like that for something so simple (and I'm sure Laurent does so even less ;)), furthermore we would need to re-implement the type trait because we're in C++98.

Why std::is_integral? Wouldn't std::is_arithmetic be better for this? That way you have only a single function for each operator instead of floats plus integer types. It would include double, but people should be aware of the implications and still allowed to use it if they want in my opinion.

D / Re: DSFML hits version 2.1!
« on: October 10, 2015, 07:19:32 pm »
Yes please to both!

That would be fantastic, thanks!

D / DSFML hits version 2.1!
« on: October 07, 2015, 09:00:14 am »
I know I know. Version 2.1?! I'm so far behind! (blame school)

This is an important milestone for the project though. There was a ton of bug fixes (mostly with the api), and I even managed to put up a (crappy) website featuring documentation, tutorials, and downloads. It also passes all unit tests, meaning everything should be functional now.

Checkout the repo here and the C binding this wrapper uses as a backend here.

D / Re: Drawing text to a Image object
« on: September 11, 2015, 01:55:42 am »
 Ah, that makes sense. Well, unless you want to build the library yourself you'll have to wait a couple of days till I get the last of everything put together for the release.

Sorry for the inconvenience.

source/app.d(14): Error: mutable method dsfml.graphics.texture.Texture.copyToImage is not callable using a const object
FAIL .dub/build/application-debug-posix.osx-x86_64-dmd_2068-CD798876B80E564B1F2D02B479176F6C/ template-dfsml executable
Error executing command run: dmd failed with exit code 1.

That's a bug in DSFML. It's fixed in the 2.1-rc branch which should be released in the next few days.

Out of curiosity, why do you need to make a new image for your calendar? Is just drawing the base image and the text on top not enough?

D / Re: Tiled screens
« on: September 10, 2015, 03:37:28 am »
I can look at it, but it's going to be a couple of days before I can get to it.

What's the problem you're having?

Can you make sure that your example is as minimized as possible while still showing the issue?

D / Re: Drawing text to a Image object
« on: September 09, 2015, 07:00:03 pm »
Should be something like this:



auto capturedTexture = renderTexture.getTexture()

//do stuff with the captured texture, like save it to an image.


D / Re: Text width, and sound
« on: August 27, 2015, 05:31:47 pm »
I got sound working! I added a import (import dsfml.audio) and added a dependency in the dub.json ("dsfml:audio": "~master").

That'll do it. ;)

Those dub  warnings are caused by using "master" directly, but with the next release I'll start  tagging the repository with the version number. That should make it happy.

Pages: [1] 2 3 ... 24