Well you never know what will interest you enough :P
Tuesday, April 29, 2014
Color swatch 2
Well you never know what will interest you enough :P
Saturday, April 19, 2014
Tuesday, March 25, 2014
Unity3D mobile quicky noobie note.
So you are making something in Unity for mobile (lets say Android). You went ahead and selected your resolution in the preview window ("Game" window) And set your GUITextures with pixel inset values in the inspector. You might have even made a script that calculates things according to the screen resolution in X and Y to find ratios and what not. Then you deploy and you notice that something is off by a couple of pixels. You double check and things are ok but still get shifted in the screen.
So what gives? Well, Unity may have 1280*800 or other standard resolutions built in, but what the OS gives to the player once you actually have it running on the device is not exactly that. Remember it has the home bar. So that takes some pixels away from the real-estate, 28 pixels as far as I could tell in the case of 1280*800 screen resolution.
Just make a custom preview resolution of 1280*752 so you won't have to keep that in the back of your mind. I'm sure there are other a lot more elegant ways of solving this, this is the easiest thing I thought about.
So what gives? Well, Unity may have 1280*800 or other standard resolutions built in, but what the OS gives to the player once you actually have it running on the device is not exactly that. Remember it has the home bar. So that takes some pixels away from the real-estate, 28 pixels as far as I could tell in the case of 1280*800 screen resolution.
Just make a custom preview resolution of 1280*752 so you won't have to keep that in the back of your mind. I'm sure there are other a lot more elegant ways of solving this, this is the easiest thing I thought about.
Friday, January 31, 2014
Camera settings and their actual effect.
A friend just bought his first dSLR and immediately started taking pictures to get to know it, which is the best thing to do once you get one. Don't ogle over it; just go out and start taking pictures, while noticing what changes in your photos when you change a setting at a time.
During his first tries though the results didn't go along with the mental images he had. And I'm guessing here that the manual may be at fault a bit. Most often the manual says that you should try and expose the image correctly with the exposure meter. Yes, you should, even the cheapest of the dSLRs now have great sensors and can forgive a step up or down. (A bit underexposed or over exposed. If the circumstances are such that you can't get a perfect exposure, you can fix it later in lightroom or photoshop. Though that should be the last resort...)
Aperture for emphasis.
Manuals most of the time say that the aperture setting is for changing the lens's iris, allow more or less light in and that will make the depth of field shallow or deep. Now i know you'll yell "semantics!" and you'll be right i guess, but it should be the other way around, that the aperture setting allows you isolate a subject or bring everything in focus. I'm putting it like that to make it easier to realize just by reading it from the first time, that if you want to make a single thing stand out, that's what you'll use, instead that "it changes the amount of light through the lens and in doing so makes stuff blurry or not." People tend to think of non-sharp photos when you say blurry, instead of thinking isolated subjects with bokeh.
Shutter speed as a time function.
Same thing with the shutter. It says to keep a fast shutter to avoid shakiness in your photos. Well yeah, if the results came out shaky and you don't have Image Stabilization, tripod or steady hands, using a faster shutter will help with that. But don't think of the shutter as the thing to make your images ... not shaken. Grip the camera firmly, have the shutter button semi pressed and ready to just press it just a tad more to release the shutter and you can do well with a slow shutter speed. You should think the shutter speed as a way to express time instead, add movement and life in a still photograph. There is this thing that people say; that you should keep your shutter speed at, or above the lens's focal length, meaning that you should have 1/50 for a 50mm lens. Let me tell you that you can go handheld a lot lower than that with just a tiny bit of practice and no IS. If you want to capture a car moving fast, you can use lets say 1/200 and get a steady car, with the wheels blurry from spinning, and the trees blurry from you tracking the car. But do that with a human walking and it's just a frozen thing. May as well be standing still. Go for a slower shutter speed, one that will get your subject's limbs just starting to go blurry from movement and then use the aperture to cut down light. Want to isolate the subject as well? Use a lower ISO setting. Don't have a lower ISO setting? Well at that point you'll need to get an ND filter to cut down light I'm afraid. But the point is that there's still a way.
So don't think the settings as the way to get your exposure meter at the center. Instead think of what you want to show in the picture and use the tools for that, there lots of times you'd want to have motion blur.
During his first tries though the results didn't go along with the mental images he had. And I'm guessing here that the manual may be at fault a bit. Most often the manual says that you should try and expose the image correctly with the exposure meter. Yes, you should, even the cheapest of the dSLRs now have great sensors and can forgive a step up or down. (A bit underexposed or over exposed. If the circumstances are such that you can't get a perfect exposure, you can fix it later in lightroom or photoshop. Though that should be the last resort...)
Aperture for emphasis.
Manuals most of the time say that the aperture setting is for changing the lens's iris, allow more or less light in and that will make the depth of field shallow or deep. Now i know you'll yell "semantics!" and you'll be right i guess, but it should be the other way around, that the aperture setting allows you isolate a subject or bring everything in focus. I'm putting it like that to make it easier to realize just by reading it from the first time, that if you want to make a single thing stand out, that's what you'll use, instead that "it changes the amount of light through the lens and in doing so makes stuff blurry or not." People tend to think of non-sharp photos when you say blurry, instead of thinking isolated subjects with bokeh.
Shutter speed as a time function.
Same thing with the shutter. It says to keep a fast shutter to avoid shakiness in your photos. Well yeah, if the results came out shaky and you don't have Image Stabilization, tripod or steady hands, using a faster shutter will help with that. But don't think of the shutter as the thing to make your images ... not shaken. Grip the camera firmly, have the shutter button semi pressed and ready to just press it just a tad more to release the shutter and you can do well with a slow shutter speed. You should think the shutter speed as a way to express time instead, add movement and life in a still photograph. There is this thing that people say; that you should keep your shutter speed at, or above the lens's focal length, meaning that you should have 1/50 for a 50mm lens. Let me tell you that you can go handheld a lot lower than that with just a tiny bit of practice and no IS. If you want to capture a car moving fast, you can use lets say 1/200 and get a steady car, with the wheels blurry from spinning, and the trees blurry from you tracking the car. But do that with a human walking and it's just a frozen thing. May as well be standing still. Go for a slower shutter speed, one that will get your subject's limbs just starting to go blurry from movement and then use the aperture to cut down light. Want to isolate the subject as well? Use a lower ISO setting. Don't have a lower ISO setting? Well at that point you'll need to get an ND filter to cut down light I'm afraid. But the point is that there's still a way.
So don't think the settings as the way to get your exposure meter at the center. Instead think of what you want to show in the picture and use the tools for that, there lots of times you'd want to have motion blur.
Tuesday, January 21, 2014
Noobie trap in Unity. (Or "How time flies". Or "Time.deltaTime")
So i wanted to make a small timer in the upper left corner of my small game.
Extremely easy; you just have a variable storing float values and add Time.deltaTime on every frame to it (deltaTime is the time it takes to render a frame.)
Thing is, if you are using something other than "1" in time scale or playing with timeScale to do some slow motion effects, your timer will get out of sync with the real time that has passed. If the timer is to trigger an event in game to happen, no biggie.
If it's for stage scoring or leaderboards though, then the timer needs to be in sync.
So just take into account timeScale. Just divide Time.deltaTime by timeScale to always keep the timer counting in the same speed. (i.e. real speed, the same speed that a wall clock does).
timer+=(Time.deltaTime/Time.timeScale);
Extremely easy; you just have a variable storing float values and add Time.deltaTime on every frame to it (deltaTime is the time it takes to render a frame.)
Thing is, if you are using something other than "1" in time scale or playing with timeScale to do some slow motion effects, your timer will get out of sync with the real time that has passed. If the timer is to trigger an event in game to happen, no biggie.
If it's for stage scoring or leaderboards though, then the timer needs to be in sync.
So just take into account timeScale. Just divide Time.deltaTime by timeScale to always keep the timer counting in the same speed. (i.e. real speed, the same speed that a wall clock does).
timer+=(Time.deltaTime/Time.timeScale);
Tuesday, December 31, 2013
Wednesday, December 25, 2013
2nd Maya/Unity quicky. (animating object with multiple individual meshes)
Have you tried to put your animated FBX from Maya and it would just go to 0,0,0 when you pressed play? (If you don't freeze the model before you export it, do so. Freeze it at 0,0,0 to save some extra trouble later on)
The reason for that is that most probably you have nested the meshes under a parent mesh in the Outliner panel and then on top, you've added keyframes to that parent. At least that was my problem when throwing it in Unity.
What you should do instead is select your meshes, group them, and then go in and add your keyframes and blend shapes. Export and your combined object won't crap itself in Unity.
The reason for that is that most probably you have nested the meshes under a parent mesh in the Outliner panel and then on top, you've added keyframes to that parent. At least that was my problem when throwing it in Unity.
What you should do instead is select your meshes, group them, and then go in and add your keyframes and blend shapes. Export and your combined object won't crap itself in Unity.
Thursday, December 5, 2013
The strange animal called "photographer" and it's environment.
I've been meaning to post something like this for some time now but (being me), I would either forget about it or postpone it until "tomorrow".
Sometimes people wonder about what they can do when others are giving them angry stares or even chased away from places while trying to take photos. It's been said a lot of times by many, I didn't discover the solution to this but it does really work. It has to do with how one behaves at each location. Basically you get back what you show. By that I mean that if you are fidgety and anxious, people will look at you funny because if you weren't doing something shady, why would you be anxious?
If you go in a public place, don't just go there with your camera up in your face aiming it at people. Warm up to them first. Don't go there rushing either, make room in your day for two to three hours and go to the place you thought that there would be some nice picture opportunities and take some time to just show people that you are there with a camera, let them warm up to the idea that there's someone with a camera and might take their picture. Don't walk around with the camera in your hands ready or have it hanged around your neck like a tourist. I won't be forcing anyone on how to wear their camera, I just found it really easier and out of my way if I have the camera slung across my left shoulder coming down to my right side. I can just pull it in front of me like those movies with the marines drawing their guns :P. Just as fast and out of the way as well.
In malls or other privately owned places it's important to ask for permission and to make people realize that you just want to take some pictures and isn't stalking people. Don't shove your lens in people's faces or sharply pop up to take photos of kids... Having a couple of business cards with you is a also a nice idea in case someone wants to throw you out while you still need to stay as it helps even further in making people realize that you aren't up to something no good. Who would give out their details if they wanted to cause trouble? (I know Joker would, but if you are The Joker and want to take pics while you are on the job all the more power to you. Send a couple pics over.)
If you notice someone that glares at you for taking pictures just breath in, go over there and ask them if they would like to see the photos you took.
So, stay calm; don't rush it; be relaxed and don't forget to smile in a non threatening way :P. (It helps)
Sometimes people wonder about what they can do when others are giving them angry stares or even chased away from places while trying to take photos. It's been said a lot of times by many, I didn't discover the solution to this but it does really work. It has to do with how one behaves at each location. Basically you get back what you show. By that I mean that if you are fidgety and anxious, people will look at you funny because if you weren't doing something shady, why would you be anxious?
If you go in a public place, don't just go there with your camera up in your face aiming it at people. Warm up to them first. Don't go there rushing either, make room in your day for two to three hours and go to the place you thought that there would be some nice picture opportunities and take some time to just show people that you are there with a camera, let them warm up to the idea that there's someone with a camera and might take their picture. Don't walk around with the camera in your hands ready or have it hanged around your neck like a tourist. I won't be forcing anyone on how to wear their camera, I just found it really easier and out of my way if I have the camera slung across my left shoulder coming down to my right side. I can just pull it in front of me like those movies with the marines drawing their guns :P. Just as fast and out of the way as well.
In malls or other privately owned places it's important to ask for permission and to make people realize that you just want to take some pictures and isn't stalking people. Don't shove your lens in people's faces or sharply pop up to take photos of kids... Having a couple of business cards with you is a also a nice idea in case someone wants to throw you out while you still need to stay as it helps even further in making people realize that you aren't up to something no good. Who would give out their details if they wanted to cause trouble? (I know Joker would, but if you are The Joker and want to take pics while you are on the job all the more power to you. Send a couple pics over.)
If you notice someone that glares at you for taking pictures just breath in, go over there and ask them if they would like to see the photos you took.
So, stay calm; don't rush it; be relaxed and don't forget to smile in a non threatening way :P. (It helps)
Subscribe to:
Posts (Atom)