Center object and fix scaling - blender

I have imported my ZBrush model of some glasses into Blender.
For some reason, the glasses are not centered at all, and I'm having a hard time to navigate it.
I would like to center it so take I can easily navigate around it.
I think the glasses are also not correctly scaled, but I guess I should care about that later.
I have uploaded my model here:
http://pasteall.org/blend/index.php?id=45773
Can anybody tell me how this should be done?
Thank you very much!

Bottom menu: Object -> Transform -> Origin to Geometry
[N] menu: set all three location values to 0.0
Profit
The first step makes sure the origin of your object lies in its geometric center. Currently, the origin is far, far below the glasses. The second step then simply moves your glasses to the center of the coordinate system.
Also, in the 'N' menu (hit 'N' to open it, will show up on the right hand side), you can set the scale just as easily as you have just set the location. Once you are happy with the scale, you might want to use Apply -> Scale (you can get that menu via CTRL+A) to make sure the new size will be used when exporting the model, for example.
Hope this helps. Oh, also: there is a dedicated Blender Stack Exchange.

Related

Rigify Animbox addon Armature origin not moving problem

I am using Rigify Animbox when move my Armature and start animation it move last position and when go to edit mode it show many link that connect with Armature.
this link can't set origin or can't move please help me how can fix it.
please see below video so you can better understand my problem.
Link: https://screenrec.com/share/AkR59zCZrL
thanks in advance
You probably have a keyframe in Object mode. That makes the whole armature jump to the center of the world (which is where the keyframe is recorded). Just delete all keyframes on the object level and you'll be able to move the Armature object.

Unreal Engine 4 minimum distance of camera from object

I placed a standard Camera in front of a moving Actor. When I set the current view to this camera I noticed a strange behaviour: If the actor get really close to another object on the scenario (a default cube) it disappear from the view. It looks like the camera is getting into the cube. I'm pretty sure the camera is not colliding with the cube because the actor has a couple of bumpers that prevent the side where the camera is placed to collide with other objects and the whole camera mesh is placed fully 'inside' the actor. The problem maybe is related with the size of the actor that's about 40cm x 30cm x 10cm. The observed cube is 1mt x 1mt x 1mt, the minimum distance of camera from cube is around 3 cm.
Sounds to me like you're experiencing an issue with an object passing your camera's "clipping plane." In the 3D world, this is simply just draw distance minimum and maximum values. For more information on what you are experiencing, check out this brilliant explanation by Autodesk: https://knowledge.autodesk.com/support/maya/learn-explore/caas/CloudHelp/cloudhelp/2018/ENU/Maya-Rendering/files/GUID-D69C23DA-ECFB-4D95-82F5-81118ED41C95-htm.html
Now, let's fix the issue! In Unreal Engine, it's super easy. Go into your Project Settings/General Settings. There is a value called Near Clip Plane, which simply changes the minimum clipping value for Camera components. I would bet making this value smaller will fix your issue! For a visual representation, check out this tutorial by Kyle Dail: https://www.youtube.com/watch?v=oO79qxNnOfU

TILED editor - object placement possible to snap to grid in Object Layer?

thanks again in advance for any time spent helping me.
Thankfully, I have been able to import TMX to libgdx game without much of a problem, however this is now the first time of using Object Layer, for which at this moment in time I only want to include Platforms as the object (ie. I have 1x Tile Layer showing my background image and 1x Object Layer above). Now I've seen that I can just draw lines and/or boxes, circles etc to create 'zones' which I can pull into my code (goodness only knows how atm but I'll figure that later/soon )
But I see in Tiled that the button - Insert Tile (T) - exists.
I'm trying to use it but when the tile im using as a platform is placed it goes exactly where the mouse is pressed and I can't move it other than delete it. I'd just like to copy-paste a whole row of them for now and Level1 can just be 50 tiles in a flat line just so I can get it all working. It seems weird to me that Tiled can't do this but Ive spent ages looking for a way and can't find it.
Am I missing something or is this just not possible? And if the latter, how does an experienced tiled user (who's making a 2d platformer) go about creating such a simple example above in the Tiled environment?
What a noob - I answered my own question. The option I needed was in the 'View' dropdown menu -> 'Snap To grid' LOL

Objective-C draw a path and detect when it closes (forms a closed shape)

I'm fairly new to game programming (but not to programming) and I want to create a space ship which leaves a trail on the screen. Now my problem is to come up with a solution how to detect if the trail left from the ship forms a closed shape - eg. if the ship left a trail around an object, the object is caught inside its trail so to speak.
The direction I'm thinking is to draw the path of the trail on an image not visible on the screen and every now and then try to fill it with certain color and then check if fill is caught within the trail path. However it seems like a lot of overhead.
Any ideas how to do that? I'm using cocos2d if that's of any help
In game programming you often need to think more mathematically than visually.
First does your ship continuously leaves a trail on the screen? If yes, then it will be easier to know when the shape closes : you just have to remember the coordinate where your ship started to leave a trail, then wait for the trail to approach this coordinate another time (for example within a radius of 10 pixels, or else the user will need to be really accurate to hit exactly the same pixel to close the shape).
The visual representation of the trail is only here for the user, you'll never use it to compute anything. What you will do is to keep in memory the path followed by the ship's trail : a polygon, which is nothing else than the list of coordinates it followed.
Then after you know that your shape is closed, you have to determine if an object is inside your polygon or not. It's possible that objective-c or cocos2d (I don't know much about it) already contains a built-in function to know if a point is inside a polygon. In java there is the Polygon class which makes this really easy. If you don't find anything you can do it yourself, there are already great answers about this subject on SO, here is a nice one : How can I determine whether a 2D Point is within a Polygon?

Is it possible to animate markers in ArcMap?

I'm completely new to ArcGIS and ArcMap, but someone suggested this program to me for a project I'm working on.
I would like to animate individual entities on a map, and was wondering if it is possible to do so in ArcMap. I asked this earlier here and a member directed me to a tutorial on animating in ArcGIS. The animation in the guide was over a map spread (ie. each pixel on the map displays, say, a different color to indicate population data in the area). However I realized that if I zoom in a lot, eventually the image will degenerate into pixels, which is why I need an actual object to mark a certain point. I checked some online tutorials and it seems like we can place markers on the map. Can someone tell me if it is possible to animate these markers (for example via a for-loop)? And if so, could you point me in a direction where to start?
Thanks in advance!
You can animate layers in ArcMap is the short answer. Its not as simple as using the timeline feature in Google Earth for example though. But then ArcMap is much more than just a visualization tool.
This help page on the ESRI web help looks like a good place to start.
I'm not 100% sure what you mean by the image degenerates into pixels. Are you saying that the markers were single points in the layer. Unlike Google Earth you are not confined to simply plotting points on the map. You can draw completely arbitrary shapes in ArcMap, which can be defined to cover actual areas of the map, so when you zoom-in the shape gets larger.
The way you need to load data into ArcMap to produce an animation isn't too simple. There might be other ways to do this, but the way I know of is to generate a NetCDF file. This file contains a 3D matrix of layer data, where each layer is separated through time. Because you generate a matrix, you are effectively placing a raster image over the map. Thus if you want to cover a large area, each matrix becomes large, and you multiply that by the number of time slices you wish to animate over.
Once you have a NetCDF file with your data in however, getting ArcMap to animate it and produce say a .avi file is pretty simple.
You could try just loading some of the example NetCDF datasets into ArcMap to see how/if they will work to get you started.
Hope that helps.
The upcoming v10 will have better time-aware capabilities, which will allow for animation.