I'm desperately trying to access files using an Android device over a network. In our home, we have a RAID that is linked to our network (so we need to be logged into our wifi to access it), and in it are some image files I use for my application on the PC. I am attempting to recreate this program onto android, but one problem I have come across is I cannot execute the above. For example, before I only needed to write:
'HOME_PC' being a computer linked into the network and a raid harddrive installed to it.
The first question is, have you understood what I am asking? because I'm not very good at explaining
and second is, is there a way to access files over a network using an android device?
Any help would be appreciated, and if any further explaining is needed, just ask :)
Quick question really... I am creating a 'Learn French' program in processing, and I allow the user to create 'Question Sheets' in a txt file. For some reason processing cannot read any accented letter (at least from a txt file), and when it should be displayed a rectangle symbol replaces it.
I have decided to get the user to use <u for ú and ^i for î etc.
I have implemented this by reading each line of the txt file, and check in that line for those combinations I have shown above, and do any necessary replacements. Now, as you can see below I use a lot of .replace() functions, is this alright? (in terms of lag and memory) Or is there a better way? (also I only update the modified finished string once when the program loads, so this isn't running all the time):
This post is probably far too complicated for what it's worth, but I have to go very soon and it would be best if I submitted it beforehand, so apologies in advance.
I have been looking everywhere on how to create an input box using the built-in android virtual keyboard but have found nothing. Is this possible in processing? Is there a library/hidden function to allow this?
I'm trying to use 'link()' to open folders (is this the best way to?) and everything works fine unless it's name has a space in. Otherwise I get a "java.net.URISyntaxException: Illegal character in path at index 17: C:/Users/KingD/My Documents" error.
If anyone can offer a possible solution it would be much appreciated :)
I'd like to ask if it is possible in processing to open a folder via Windows Explorer for the user. I have tried the 'open()' command, but that only seems to open files, like txt, png etc.
Hi all!
I have a bit of a challenging question to ask...
I'm making a paint editor with 10px wide cells and currently I have it set so every frame it colours the cell beneath the mouse red, but this leaves gaps between the previous and current mouse positions. As I treat each cell as a rectangle, I cannot use the provided line(), vertex(), rect() etc. functions. I have simplified my program for the purpose of this question below:
int wid, hei; //amount of cells on the canvas
color[][] colours;
void setup() {
size(500, 500);
noStroke();
wid = int(width/10); hei = int(height/10);
colours = new color[wid][hei];
for (int x=0;x<wid;x++) {
for (int y=0;y<hei;y++) {
colours[x][y] = color(255, 232, 200); //setting all pixels to a cream colour
}
}
}
void draw() {
//displaying all cells with the appropriate colour
Probably another 'newbie' question, but is there a way to detect if the home or end key has been pressed? I have been researching for some answers but haven't had much luck, could anyone help me with my troubles? :) If you could it would as always be greatly appreciated.
I am trying to work out a way I can choose a random integer between 0 and 10, but not roll the same number as the previous roll. So:
the first roll, it would choose any number between the specified range - say I roll a 5.
the second time, it would choose an integer within the boundaries, but excluding the previous number - say I roll a 9.
the next roll, again it would be within 0 and 10, but only 9 is now excluded, 5 is put back in the available numbers - and for example purposes, I roll a 5.
and so on...
Any help would be greatly appreciated :)
KingD.
Also, if I'm being a bit vague, ask and I'll explain further :)
I am working on a puzzle game, and I'm having trouble layering the objects so that when one of the pieces is 'picked up' by the mouse, it is drawn to the front until another is placed on top. Now, I understand that the ones drawn last in the program will be the ones visible at the front, but the trouble is I don't know how to achieve this.
At the moment, I have made it so that the one being picked up is drawn to the front, but as soon as the mouse button is released it goes back to its normal depth. This would be fine, but as I create the pieces like this:
01, 02, 03,
04, 05, 06,
07, 08, 09.
... piece number 01 will always be drawn behind 02 etc., which gives the game away as it shows where the piece is meant to be.
I have been looking around for an answer to a similar question for a while, but I haven't found any which match my problem. Any help on how to alter the depth of objects would be greatly appreciated :)
Thanks in advance,
KingD.
P.S. Sorry if I have been a bit vague, please ask if something I've said doesn't make sense :)
I would like to know if it is possible to manually set the origin of an image? What I mean by this is that currently, you have to say 'imageMode(CENTER)' and then use an image which I have had to move around in the paint software so that the center is the place I want the origin to be. However, I find this tedious and inefficient.
What I would like to know is if it is possible to move the origin of the image using code?
Well, what I would like to do is create a variable with a value between -5 and -1 or 1 and 5? I'm aware I could do it a long winded way but I was wondering if there was an easy way of doing it? For example, in the programming language I have just moved on from (GML - GameMaker Language) there is a choose() function which has an equal chance of choosing each of the arguments, which would look like this in processing:
int value = choose(int(random(-5, -1), int(random(1, 5));
This would give the variable 'value' a value ranging between either -5 to 1 or between 1 to 5.
Is there an easy way of doing this in processing?
Thanks in advance =)
KingD.
P.S. Sorry if I haven't been clear enough. Let me know and I'll be more clear if necessary =)