projection

Determining camera parameters

Given a picture taken by a simple digital that contains an image of a rectangle of known dimensions. How can I - to some degree of accuracy - determine the parameters of this camera? I am mostly interested in Pan-, Tilt- and Swing angles. Optionally distance to the rectangle would be nice. I acknowledge the fact that the focal length ...

Eclipse RCP - Internals of projection (folding) service

I need to make custom text folding as described here: http://stackoverflow.com/questions/1017375/can-i-merge-syntax-coloring-and-folding-or-projection-colored-from-master-docume I'm digging through code, but its very perplexed... and I cant get access to some classes. I still haven't found what class decides what to show when ProjectionA...

Inverse 3D (triangle) projection

Hello, I have a 3D math problem which I just can't seem to solve. I have data of 3 points. The data is a (2D) coordinate on a plane, floating somewhere in 3D space. I also know the (2D) coordinate of the projection. That results in the following array of data: [[[x1,y1], [px1,py1], [[x2,y2], [px2,py2], [[x3,y3], [px3,py3]] Where t...

2D vector projection in Python

The code below projects the blue vector, AC, onto the red vector, AB, the resulting projected vector, AD, is drawn as purple. This is intended as my own implementation of this Wolfram demonstration. Something is wrong however and I can really figure out what. Should be either that the projection formula itself is wrong or that I mistake...

How to use NHibernate Projections to retrieve a collection.

I am lazy loading the collections, and also because there are so many fields within the person table, I am writing a projection function to retrieve only certain properties. It works with properties, just not collections of other entities. I would be fine if they were loaded in as proxies and i could get them later, but right now it just...

Lambert conformal conic map projection to get x,y values of a grid in java

I am using the NetCDF 4 java library from unidata to read GRIB2 files and am now trying to find a way to get timezone offsets for a given latitude/longitude. I have a .flt file for the northern hemisphere that contains all of this information and I know how to read it, I just don't know how to do the map projection properly. I am able...

mapping from normalized device coordinates to view space

Hey there! I'd like to map from normalized device coordinates back to viewspace. The other way arround works like this: viewspace -> clip space : multiply the homogeneous coordinates by the projection matrix clip space -> normalized device coordinates: divide the (x,y,z,w) by w now in normalized device coordinates all coordinates wh...

Linq to SQL: Projections, ViewModels, non translatable queries

My application has to deal with large amounts of data, usual select size is about 10000 rows. In order to improve performance it is recommended only to select the data needed. When i have to do calculations or any meaningful business i am comfortable with selecting all the data in order to instantiate my model correctly so i can rely on...

Reuse component in projection (NHibernate)

Is it possible to reuse a component mapping in a projection? Here is the mapping for the Vendor entity: <class name="Vendor" table="vendor"> ... <property name="Name" column="Name" /> <component name="Address" class="MyProject.Address, MyAssembly" > <property name="Street" column="street" /> <property na...

Projecting only some part of SVG on Google Map

I have SVG files, which I'd like to: export and use as custom ground overlay with flat Euclidean projection (econym.org.uk/gmap/example_custommapflat.htm). take only polygons and project them on Google Map My SVG files have some rules in common: they all are 4096x4096px main objects of the map are centered I have done some experi...

Show lat/lon points on screen, in 3d

It's been a while since my math in university, and now I've come to need it like I never thought i would. So, this is what I want to achieve: Having a set of 3D points (geographical points, latitude and longitude, altitude doesn't matter), I want to display them on a screen, considering the direction I want to take into account. This is...

Efficiency of perspective projection vs raytracing/ray casting

I have a very general question. I wish to determine the boundary points of a number of objects (comprising 30-50 closed polygons (z) each having around 300 points(x,y,z)). I am working with a fixed viewport which is rotated about x,y and z-axes (alpha, beta, gamma) wrt origin of coordinate system for polygons. As I see it there are two ...

How to call fromLatLngToDivPixel in Google Maps API V3?

I know that method exists and is documented, but I don't know how to get an MapCanvasProjection object. ...

Get X Y from lat lon in ozi calibrated map

I have some .map OZI calibrated maps. From those .map, I can get some calibration points (x y in the jpeg picture + lon lat in WGS84). MMPXY,1,142,142 MMPXY,2,5217,142 MMPXY,3,5217,3422 MMPXY,4,142,3422 MMPLL,1, -0.269639, 39.626293 MMPLL,2, -0.186306, 39.626293 MMPLL,3, -0.186306, 39.584626 MMPLL,4, -0.269639, 39.584626 With ...

How do i use perspective projection in this library

i found a library called pyeuclid and it seems to do what i want in respect to 3D math. it contins a 3D vector class and a 4X4 matrix class capable of transformations like rotate,translate and scale. matrix creation is simple, simply pass along the arguments and the matrix is created. >>> m = Matrix4() >>> m.translate(50,50,50) Matri...

Hibernate: Projection of a many-to-one in a Criteria

Hi all, I am playing around with the hibernate Criteria API for the first time recently. I was trying to do the equivalent of this HQL "select t.userTbl from Task t" userTbl property is a many-to-one from Task. The Task.userTbl relationship is lazy. So I came up with this Criteria criteria = session.createCriteria( Task.class, "t"...

Use fewer columns on SQL query through Hibernate Projections on Entity with ManyToOne relation

I'm trying to build a smaller SQL, to avoid the "select * from A" that is being build by default for hibernate Criteria. If I use simple fields (no relation), through "Transformers", I have can manage to have this SQL: select description, weight from Dog; Hi, I have this Entity: @Entity public class Dog { Long id; String descr...

Function for perspective projection of a matrix in C++

Hi, Does anyone have a function that returns the perspective projection of a 3x3 matrix in C++? Matrix Perspective() { Matrix m(0, 0, 0); // Creates identity matrix // Perspective projection formulas here return m; } ...

Adding a projection to an NHibernate criteria stops it from performing default entity selection

I'm writing an NHibernate criteria that selects data supporting paging. I'm using the COUNT(*) OVER() expression from SQL Server 2005(+) to get hold of the total number of available rows, as suggested by Ayende Rahien. I need that number to be able to calculate how many pages there are in total. The beauty of this solution is that I don'...

OpenLayers Google Maps Projection Problem w/ KML

Hi. This is my first time on stackoverflow and working with Openlayers & Google Maps. I've been browsing different forums & sites, including OpenLayers.org, to solve my issue. I've done searches on a combination of the following: openlayers, google map projections, and spherical mercator... but I have not found a solution. Problem: T...