Vulkan extent not resizing - vulkan

I have started a vulkan project using glfw and then realized that I can't use it, so I made my own windowing library, integrated it in my project and now every time I resize the window, minImageExtent and maxImageExtent from surface capabilities don't change, they are the original size that I created the window with. The windowing library can be found here: https://github.com/Sucuturdean/ntd/blob/master/ntd/window.h and if you need any code snipets from the actual code please say so in the comments.
Edit: I am developing on linux and the drivers work since I have tested with other applications.

Related

Why are wxWindows and PangoCairo used together?

I'm probably way out of the loop, but it seems weird to use a native look GUI library and then - if you're not using wxGTK - shoehorn in a text renderer from a different GUI library. What's the deal here?
I think I understand your point. Using GTK (and Pango Cairo) on Windows, by telling wxWidgets to use internally GTK seems duplicating window managers.
It's just a matter of taste. GTK in Windows does call Windows API to do windowing. But some users like the GTK-way for windows, menus, and other controls instead of the native Windows-way, and wxWidgets provides this feature (in addition, of course, of the native usage, keeping native look&feel).
Anyhow, GTK on Linux calls internaly X11 or Wayland for handling windows and menus. Do you also call this "duplicating"?
The question seems to stem from a mistaken assumption, so it's hard to answer it, let me rather explain how things really are instead:
Cairo-based wxGraphicsContext can be optionally used under MSW because this allows to produce exactly the same graphics output under all platforms, which can be important for some kinds of applications. However it is not used by default, you need to explicitly request it, and if you don't you'd be using GDI+ or Direct2D, both of which are perfectly native libraries.

Modern language IDE similar to QBasic?

I'm trying to find a modern environment similar to what I found great about QBasic but making up for the flaws. The purpose of this is to code with my 6 year old son.
I'm looking for an IDE that uses a modern language, has the ability to draw graphics and play audio, and doesn't force the User to jump around much between coding and running their application.
In QBasic you had basically two modes: Edit and Run. There were no third party libraries required for creating graphics or generating Audio tones (that I remember). You never had more than one "window" opened at a time.
Is there a modern day equivalent IDE which uses a modern language that provides what I'm looking for?
I don't want him to have to jump around between various windows, try to wrap his mind around window toolkits, understand the command line, or use OOP just to get started. My end goal is to create simple graphical games with him -- not printing text out to the console.
(Preferably cross platform or useable on Mac OSX since that's what we have at the house. Preferably Python based since that's my language of choice.)
QBasic is a great option. You can purchase an old PC from a thrift store and run QBasic on it. There is the option of QB64 which can run on both Mac and Windows. Hope this is helpful.
I'd suggest QB64, almost 100% compatible with QBasic/QuickBasic but runs on Windows.
You could maybe try Small Basic, it aimed to recreate the ease-of-use and educational purposes of the old BASIC languages build into home computers from the 1980s
The Small Basic project was initiated following this article on Salon:
Why Johnny can’t code (David Brin, 2006)

Failed Win8 App Certification: 3.10 - If your app includes an ARM or a Neutral package it must support Microsoft Direct3D feature level 9_1

My C# app uses a C++ WinRT component I've written to get a list of system fonts using Direct X.
This is based on this example:
http://msdn.microsoft.com/en-us/library/dd756582(v=VS.85).aspx
My app is published in the store, but my latest update failed to pass the store review process on point 3.10 complaining about my use of Direct 3D and how this might not run on ARM tablets. As far as I know I'm not using Direct 3D and the only Direct X feature I'm using is GetSystemFontCollection.
How can I make sure I don't fail this requirement and do I need to remove some rogue reference in my component to Direct3D?
Also, why am I failing this now, when it passed before?
Did you target all three platforms or choose any cpu in your release?
Does this page help:
http://msdn.microsoft.com/en-gb/library/windows/apps/hh994923.aspx
It looks like you may have inadvertently requested a higher level.
I submitted again and included a note to the tester explaining that my app didn't use any Direct 3D features, and I told them the exact DirectX function I did use.
I still failed, but the Direct3D reason was no longer one of the reasons.
Apparently my app is crashing, which was another failure reason the first time round, but I thought this must be related to the Direct3D problem. I can't reproduce the crash, but at least I now know that I can stop looking at my use of DirectX. This was a red herring.

Objective-C in Mono

I have a .NET application, which I want to port to OSX. Up to now I used a DirectShow DLL for WebCam handling. Can I use an Objective-C DLL for Mono? How? I'm a newbie on Mac. Is there an existing (WebCam handling) solution for this? Is there a better solution?
You want to use the QTKit framework to do this, in particular you can use the QTCaptureView as a reusable NSView that you can embed in an existing window or in an application to do the actual video capturing.
I have just added support for capturing to the MonoMac bindings a few minutes ago after I saw your question, so you will need to do a little bit of work.
Steps:
Install Mono, MonoDevelop and the MonoMac addin as described here: http://mono-project.com/MonoMac
Download the latest sources for MonoMac and MacCore from Github: http://github.com/mono/maccore and http://github.com/mono/monomac
Update the MonoMac.dll to the latest version, by going into the monomac/src directory and typing "make update"
At this point you should be able to use the QTCaptureView in your MonoMac applications like any other NSView. A tutorial showing the use of the API in Objective-C is here:
http://developer.apple.com/library/mac/#documentation/Cocoa/Conceptual/QTKitApplicationTutorial/BuildingaSimpleQTKitCaptureApplication/BuildingaSimpleQTKitCaptureApplication.html#//apple_ref/doc/uid/TP40008155-CH8-SW1
You can just use the equivalent versions in C#
I'm not sure what you mean by "an object-c dll for Mono".
Your absolute best approach is to learn the platform you're targeting and port only the logic and general architecture.
To access cameras, microphones, line-ins, etc. on Mac OS X, use QTKit (Quicktime Kit). It's mind-numbingly simple to set up a web cam view, record to files, grab frames, etc. It's built in and designed to make this sort of thing mostly drag-and-drop for developers.
MonoMac is just one alternative. There are Monobjc, CocoSharp, NObjective, MObjc / MCocoa and ObjC# (I cannot choose between them). Theese are all "bridges" between Mono and Cocoa, what mean you can use Cocoa API in Mono application. But I don't want to use the API directly. I just want a dinamically linked library, which provide me some function for WebCam handling (as I said, I did this up to this time on Windows). In other words: I need a wrapper in Mono for QTKit.
PS: If I rewrite the application in object-c that means several months, and double work in the future when the application will grow. I love object-c but I hate to work unnecessary.
I tried the accepted code in XCode, and when I tried to port to Monodevelop, several classes are missing, eg. QTCaputureSession, QTCaputreDeviceInput, CVimagebuffer.
(Sorry, I cannot edit my previous messages, this is another account.)

Building Cross Platform app - recommendation

I need to build a fairly simple app but it needs to work on both PC and Mac.
It also needs to be redistributable on a disc or usb drive as a standalone desktop app.
Initially I thought AIR would be perfect for this (it ticks all the API requirements), but the difficulty is making it distributable, as the app would require the AIR runtime to be installed to run.
I came across Shu Player as an option as it seems to be able to package the AIR runtime with the app and do a (silent?) install.
However this seems to break the T&C from Adobe (as outlined here) so I'm not sure about the legality.
Another option could be Zinc but I haven't tested it so I'm not sure how well it'll fit the bill.
What would you recommend or suggest I check out?
Any suggestion much appreciated
EDIT:
There's a few more discussions on mono usage (though no real conclusion):
Here and Here
EDIT2:
Titanium could also fit the bill maybe, will check it out.
Any more comments from anyone?
EDIT3 (one year on): It's actually been almost a year since I posted that question but it seems some people still come across it every now and then, and even contribute an answer, even a year later.
Thought I'd update the question a bit. I did not get around to try the tcl/tk option at the end, time constraint and the uncertainty of the compatibility to different os versions led me to discard that as an option.
I did try Titanium for a bit but though the first impressions were ok, they really are pushing the mobile platform more than anything, and imho, the desktop implementation suffers a bit from that lack of attention. There are also some report of problems with some visual studio runtime on some OSs (can't remember the details now though).. So discarded that too.
I ended up going with XULRunner. The two major appeals were:
Firefox seems to work out of the box on most OS version, so I took it as good faith that a XULRunner app would likely be compatible with most system. Saved me a lot of testing and it turned out that it did run really well on all platforms, there hasn't been a single report of not being able to start the app
It's Javascript baby! Language learning curve was minimal. The main thing to work out is what the additional xpcom interfaces are and how to query them.
On the down side:
I thought troubleshooting errors was a sometimes difficult task, the venkman debugger is kinda clunky, ended up using the console more than anything.
The sqlite interface is a great asset for a desktop app but I often struggled to find relevant error infos when something didn't work - maybe i was doing it wrong.
It took a little while to work out how to package the app as a standalone app for both PC and Mac. The final approach was to have a "shell" mac app and a shell pc app and a couple of "compile" script that would copy the shells and add the custom source code onto it in the correct location.
One last potential issue for some, due to the nature of xulrunner apps, your source code will be deployed with the app, you can use obfuscation if you want but that's something to keep in mind if you want to protect your intellectual property
All in all, great platform for a cross-platform app. I'd highly recommend it.
Tcl/Tk has one of the best packaging solutions out there. You can easily wrap a cross-platform application (implemented in a fully working virtual filesystem) with a platform-specific binary to get a single file executable for just about any modern desktop system. Search google for the terms starkit, starpack and tclkit. Such wrapped binaries are tiny in comparison to many executables these days.
Many deride Tk as being "old" or "immature" but it's one of the oldest, most stable toolkits out there. It uses native widgets when such widgets exist.
One significant drawback of Tcl/Tk, however, is that it lacks any sort of printing support. If your application needs to print you'll have to be a bit creative. There are platform-specific solutions, and the ability to generate postscript documents, and libraries to create pdfs, but it takes a little extra effort.
Java is probably your best bet, although not all Windows PCs will necessarily have Java (most should). JavaFX is new enough you can't count on it - you'll probably find a lot of machines running Java 1.5 or (shudder) 1.4. I believe recent Mac OS still ships with 1.5 (latest version may have changed to 1.6).
Consider JavaFX
It would run everywhere with a modern JRE ..!
AIR could be an option, but only if you don't mind distributing two different files (the offline runtime installer and your app), and expecting the user to run one and then the other. You do have to submit an online form at Adobe's site saying you agree to distribute the offline installer as-is, rather than digging out individual DLLs or whatever, before they give you the installer.
Unfortunately there's currently no way to get both an AIR app and the runtime to install from one file though. I'm not sure what the deal with Shu is, or whether it's doing anything that isn't kosher.
i would recommended zink. it has all the functionalities you require for desktop. however, the las time i used it it was a bit glitchy.
i was hung up by trying to write a 6M file to the disk. thought it trough and changed the code to write 512K chunks at a time (3min work, fast).
probably it still has some little annoying glitches like making you think on root lvl but the ease of use and the features are just way too sweet to ignore.